Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 400
Default Macros: Why 'wbook.xls'!MyMacro

I have never seen this befo

In my workbook wbook.xls (Excel XP) I have several macros. On Tools | Macro
| Macros, a dialogue comes up showing the available macros. One of the macros
MyMacro is listed as 'wbook.xls'!MyMacro and selecting it does NOT enable the
Run button. The Run button does get enabled with the other macros - all of
them are in the Worksheet and are listed as ThisWorkbook.MyMacro(n).

However, after Alt + F11, I can step through MyMacro.

There is no open dialogue or error message, no formulaes in the workbook,
and there is no cell editing in progress.

I am completely baffled by this: can someone explain what is happening?

Thanks.
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9,101
Default Macros: Why 'wbook.xls'!MyMacro

The top level main macro (SUB) cannot have any parameters. the main macro can
call other macros (subs or functionions) with parameters.

"AA2e72E" wrote:

I have never seen this befo

In my workbook wbook.xls (Excel XP) I have several macros. On Tools | Macro
| Macros, a dialogue comes up showing the available macros. One of the macros
MyMacro is listed as 'wbook.xls'!MyMacro and selecting it does NOT enable the
Run button. The Run button does get enabled with the other macros - all of
them are in the Worksheet and are listed as ThisWorkbook.MyMacro(n).

However, after Alt + F11, I can step through MyMacro.

There is no open dialogue or error message, no formulaes in the workbook,
and there is no cell editing in progress.

I am completely baffled by this: can someone explain what is happening?

Thanks.

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 199
Default Macros: Why 'wbook.xls'!MyMacro

I maybe misread but I think Poster's ThisWorkbook.MyMacro(n) means
ThisWorkbook.MyMacro1, ThisWorkbook.MyMacro2 and the like. So, I guess
there is no Subs with arguments and he could run the macros like
ThisWorkbook.MyMacro1 except for the macro 'wbook.xls'!MyMacro.

Keiji

Joel wrote:
The top level main macro (SUB) cannot have any parameters. the main macro can
call other macros (subs or functionions) with parameters.

"AA2e72E" wrote:

I have never seen this befo

In my workbook wbook.xls (Excel XP) I have several macros. On Tools | Macro
| Macros, a dialogue comes up showing the available macros. One of the macros
MyMacro is listed as 'wbook.xls'!MyMacro and selecting it does NOT enable the
Run button. The Run button does get enabled with the other macros - all of
them are in the Worksheet and are listed as ThisWorkbook.MyMacro(n).

However, after Alt + F11, I can step through MyMacro.

There is no open dialogue or error message, no formulaes in the workbook,
and there is no cell editing in progress.

I am completely baffled by this: can someone explain what is happening?

Thanks.

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 400
Default Macros: Why 'wbook.xls'!MyMacro

Any (public) sub that take one or more parameters are automatically excluded
from the dialogue box that follows Tools | Macro | Macros.

My problem is that a macro appears in the dialogue box (in a peculiar way)
and it cannot be run. I need to understand why.

"Joel" wrote:

The top level main macro (SUB) cannot have any parameters. the main macro can
call other macros (subs or functionions) with parameters.

"AA2e72E" wrote:

I have never seen this befo

In my workbook wbook.xls (Excel XP) I have several macros. On Tools | Macro
| Macros, a dialogue comes up showing the available macros. One of the macros
MyMacro is listed as 'wbook.xls'!MyMacro and selecting it does NOT enable the
Run button. The Run button does get enabled with the other macros - all of
them are in the Worksheet and are listed as ThisWorkbook.MyMacro(n).

However, after Alt + F11, I can step through MyMacro.

There is no open dialogue or error message, no formulaes in the workbook,
and there is no cell editing in progress.

I am completely baffled by this: can someone explain what is happening?

Thanks.

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 400
Default Macros: Why 'wbook.xls'!MyMacro

Your understanding is spot on.

None of the macros take arguments; still can't understand why the
'wbook.xls'!MyMacro appears the way it does & how this issue can be resolved.


"keiji kounoike" <"kounoike A | T ma.Pik" wrote:

I maybe misread but I think Poster's ThisWorkbook.MyMacro(n) means
ThisWorkbook.MyMacro1, ThisWorkbook.MyMacro2 and the like. So, I guess
there is no Subs with arguments and he could run the macros like
ThisWorkbook.MyMacro1 except for the macro 'wbook.xls'!MyMacro.

Keiji

Joel wrote:
The top level main macro (SUB) cannot have any parameters. the main macro can
call other macros (subs or functionions) with parameters.

"AA2e72E" wrote:

I have never seen this befo

In my workbook wbook.xls (Excel XP) I have several macros. On Tools | Macro
| Macros, a dialogue comes up showing the available macros. One of the macros
MyMacro is listed as 'wbook.xls'!MyMacro and selecting it does NOT enable the
Run button. The Run button does get enabled with the other macros - all of
them are in the Worksheet and are listed as ThisWorkbook.MyMacro(n).

However, after Alt + F11, I can step through MyMacro.

There is no open dialogue or error message, no formulaes in the workbook,
and there is no cell editing in progress.

I am completely baffled by this: can someone explain what is happening?

Thanks.


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Progress Bar Macro Incorporated Into MyMacro ryguy7272 Excel Programming 5 October 12th 07 02:13 PM
functions in 'personal.xls' Russ Excel Programming 4 June 28th 07 10:10 PM


All times are GMT +1. The time now is 07:46 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"