Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
The macros are in:
VBA project (Filename.xls) Microsoft excel objects Sheet 1 Sheet 2 (Here is where the macros are(the sheets)) Etc... Thanks ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Stu,
So call like Call Worksheets("Sheet1").macro1 Call Worksheets("Sheet2").macro2 But make sure they are not private. Also, why have you put macros in a sheet module? If you want to call them from elsewhere it is easier to put them in a normal code module (InsertModule). -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "Stu" wrote in message ... The macros are in: VBA project (Filename.xls) Microsoft excel objects Sheet 1 Sheet 2 (Here is where the macros are(the sheets)) Etc... Thanks ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Because I don't know how to put them in a sheet module and link it to
the sheet. But i saw sheet 1, sheet 2, etc... and thought I can put it there because the macro will go with the sheet. (Im new to macros so i havent a clue what im doing most of the time) Thanks ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
When I try to run the macro which opens macros from other sheets i get
an error message saying: Microsoft Visual Basic (In top bar) Subscript out of range any ideas as to why this happens? Thanks ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Stu,
That sounds as if you have got the name of the worksheet wrong. As I suggested, it would be of the format Call Worksheets("Sheet1").macro1 and make sure it is not private. But again I suggest that you put it in a normal code module, which you can create from the Insert menu. -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "Stu" wrote in message ... When I try to run the macro which opens macros from other sheets i get an error message saying: Microsoft Visual Basic (In top bar) Subscript out of range any ideas as to why this happens? Thanks ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
#6
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have now created a module and its much easyer than what i was doing.
Thanks Stu ------------------------------------------------ ~~ Message posted from http://www.ExcelTip.com/ ~~ View and post usenet messages directly from http://www.ExcelForum.com/ |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Open file with macros | Excel Discussion (Misc queries) | |||
macro or code to open multiple workbooks | Excel Discussion (Misc queries) | |||
Macro for multiple open files | Excel Discussion (Misc queries) | |||
How to stop file open macro prompt after deleting all macros? | Excel Worksheet Functions | |||
Macro that will add data from multiple workbooks to the 1st open r | Excel Discussion (Misc queries) |