Macro Won't Run on Certain Machines

tlukareski

New Member
Joined
Apr 11, 2002
Messages
3
I searched both here and on msdn for info on this and have been unsuccessful.

I have a Macro that I created on one machine and will not run on the other. I get the following error message...

Run-time Error '1004'
Application-defined or object-defined error

Both machines are running...
WinNT 4.0 SP6
Excel 2000 9.0.4402 SP-1
VB 6.0
VB Version 8967
VBA: Retail 6.0.8714
Forms3: 2.01

I also checked the VB TOOLS->REFERENCES and they matched exactly.

Any suggestions on what to do?

Thanks-
Thomas
 

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off
Hello mate,

It's always best to post your code. In this case error 1004 as you described is a general error and could be one of many things - difficult to diagnose without seeing the code.

Regards,
Dan
 
Upvote 0
what version was the code orig from I had some code in xp that would not work in 2000 but would work in 97 and so on may pay to go through the code and debug it if you know how to do that otherwise post your code and someone will be able to do that for you maybe
 
Upvote 0
I was able to figure out the problem. I was using Windows("Workbook_Name.xls").Activate when I should have been using Workbooks("Workbook_Name.xls").Activate.

Everything works just fine now...

Thanks-
Thomas
 
Upvote 0
So the "certain" machines it wouldn't run on were all those with Windows and Excel installed on them. :biggrin:
 
Upvote 0
Hi --

for years and years i have disagreed on this but from today im convinced thisis true WHY?? no ideas yey, just wild quesses.

My cmpany has rolled out XP Win and XP Office now some of my VBA wont work, ie calculation codes,,, ???

And im still on the old server.. ODD. i get fails as break in close program menu?? no reason and heavy crashes, all codes ive used and not developed in months..

seems things do get upset.

sorry no fix,,, but i see your problems..
 
Upvote 0

Forum statistics

Threads
1,213,536
Messages
6,114,208
Members
448,554
Latest member
Gleisner2

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