ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Can't see macros with parms in Tools -- Macros (https://www.excelbanter.com/excel-programming/309160-cant-see-macros-parms-tools-macros.html)

Peter Chatterton

Can't see macros with parms in Tools -- Macros
 
I can't get macros with parameters to show up in the Macros dialog box.

Is this a bug or a feature?

Or is it me?

Hope you can help,
Peter.

win2000 excel 2002



Simon Lloyd[_555_]

Can't see macros with parms in Tools -- Macros
 
if the macro's you have written or copied over have the title like this

Private Sub() then you will not see them in the macro's list if the
have the title
Public Sub() then they will be available in the list.

Hope this is what you were after!

Simo

--
Message posted from http://www.ExcelForum.com


Peter Chatterton

Can't see macros with parms in Tools -- Macros
 
Thanks for your reply Simon, where did you find out about
Public and Private? I can't find them in the online help.


My macros mostly started off in the recorder or I edited them
into the VBE page directly.

They all were just ordinary Subs, not Public or Private.

I'm going by the example at the very bottom of p.41 of the Wrox
book on Excel 2002 VBA which has:
Sub PostInput(InputData, Target)

If I manually enter just the hidden macro name and press enter,
it tries to run but VBE says "Arg not optional".
If I enter macro11 "aa", it greys out all the buttons except Cancel,
and returns to the spreadsheet.

Thanks,
Peter.


"Simon Lloyd " wrote in message
...
if the macro's you have written or copied over have the title like this

Private Sub() then you will not see them in the macro's list if they
have the title
Public Sub() then they will be available in the list.

Hope this is what you were after!

Simon


---
Message posted from http://www.ExcelForum.com/




Stephen Bullen[_3_]

Can't see macros with parms in Tools -- Macros
 
Hi Peter,

I can't get macros with parameters to show up in the Macros dialog box.

Is this a bug or a feature?


It's a feature. You can type in the name if you want to run it, but they
aren't listed. The assumption is that these would be called from other
procedures that pass the parameter values.

Regards

Stephen Bullen
Microsoft MVP - Excel
www.BMSLtd.ie




All times are GMT +1. The time now is 07:34 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com