Missing .tmp File when copying a sheet

Lucilla

New Member
Joined
Apr 13, 2011
Messages
15
Hi All,

I need your expert support since I am stacked and I cannot find any solution.
I develop a VBA macro that works on my computer (MS Excel 2016), but when it runs on another pc it cannot work.
The errors we got are "Impossible to find the file... VB....tmp" and an error run-tim 1004 with error in the copy method in the Worksheet class.
I am just trying to copy a sheet that is present into the workbook after the first sheet:
Code:
Sub InputData()
    Check = True
    Call DefineAllVar 'Procedure in A_VariableDeclaration
    Template = Templ & Piano
    Sheets(Template).Select
    Sheets(Template).Copy After:=Sheets(HM)
    NameTemp = ActiveSheet.Name
    Sheets(NameTemp).Name = NameInput
    Sheets(NameInput).Select
...

The Sub DefineAllVar is another sub that defines Public variables, such as Templ and Piano. HM is a public const with the Home sheet name...

I really don't know where the problem is!
Thanks for any support!
 

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)

Forum statistics

Threads
1,224,521
Messages
6,179,285
Members
452,902
Latest member
Knuddeluff

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top