Home |
Search |
Today's Posts |
|
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
cannot access macro in another file
Hi All,
In my addin, I open an excel file, then call a macro in that file. I close the file, and then open another and do the same. I repeat this 8 times with different files. Everything worked fine. I modified all of the marcos exactly the same. (added the same code) Now, one of the files fails. I get an error saying: Run-time error '1004': The macro SLOPE_MONITORING_1XX_BellPit.xls'!THisWorkbook.mai n()' cannot be found. My other 8 files are called _2XX_ to _9XX_ They all work fine, it is just this one. I went though everything line by line, there is no differences between any of the files. Please help, Chad |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
cannot access macro in another file
Also, if I change the line in the addin to .Main1()
and the sub in the other file to Main1(), it still fails "Chad" wrote in message ... Hi All, In my addin, I open an excel file, then call a macro in that file. I close the file, and then open another and do the same. I repeat this 8 times with different files. Everything worked fine. I modified all of the marcos exactly the same. (added the same code) Now, one of the files fails. I get an error saying: Run-time error '1004': The macro SLOPE_MONITORING_1XX_BellPit.xls'!THisWorkbook.mai n()' cannot be found. My other 8 files are called _2XX_ to _9XX_ They all work fine, it is just this one. I went though everything line by line, there is no differences between any of the files. Please help, Chad |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
cannot access macro in another file
Nor can I call any marco from that file
"Chad" wrote in message ... Hi All, In my addin, I open an excel file, then call a macro in that file. I close the file, and then open another and do the same. I repeat this 8 times with different files. Everything worked fine. I modified all of the marcos exactly the same. (added the same code) Now, one of the files fails. I get an error saying: Run-time error '1004': The macro SLOPE_MONITORING_1XX_BellPit.xls'!THisWorkbook.mai n()' cannot be found. My other 8 files are called _2XX_ to _9XX_ They all work fine, it is just this one. I went though everything line by line, there is no differences between any of the files. Please help, Chad |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
cannot access macro in another file
Got it,
I had brackets after the funciton name. I hate the little things Thanks anyways, Chad "Chad" wrote in message ... Hi All, In my addin, I open an excel file, then call a macro in that file. I close the file, and then open another and do the same. I repeat this 8 times with different files. Everything worked fine. I modified all of the marcos exactly the same. (added the same code) Now, one of the files fails. I get an error saying: Run-time error '1004': The macro SLOPE_MONITORING_1XX_BellPit.xls'!THisWorkbook.mai n()' cannot be found. My other 8 files are called _2XX_ to _9XX_ They all work fine, it is just this one. I went though everything line by line, there is no differences between any of the files. Please help, Chad |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Possible to create XL file then run XL VBA (to format & filter XL file) from Access VBA? | Excel Discussion (Misc queries) | |||
Help! Security when using a VBA macro to access an Excel File | Excel Programming | |||
how do i password protect an .xls file? how do i unlock it for automation. e.g. want to unlock and access a .xls from another .xls macro. | Excel Worksheet Functions | |||
How do I open an Access file with a macro in Excel? | Excel Programming | |||
VB Code or Excel macro to run Query/Import on Access file | Excel Programming |