Can't Find Macro In Dialog Box

  • Thread starter Thread starter JMay
  • Start date Start date
J

JMay

In my file name
AutoInsert_NewRows_WithFormulas_Repeated_Without_Constants.xls

I went into VBE Insert Module and Pasted:

Sub InsertRowsAndFillFormulas(Optional vRows As Long)
' Documented: http://www.mvps.org/dmcritchie/excel/insrtrow.htm
' Re: Insert Rows -- 1997/09/24 Mark Hill <[email protected]>
'Dim vRows As Integer
' row selection based on active cell -- rev. 2000-09-02 David McRitchie
ActiveCell.EntireRow.Select 'So you do not have to preselect entire row
xxxxxxxxxxxxxxxxxx blah, blah....
End Sub

When I go back into the spreadsheet and Alt-F8, I dont see it
(nsertRowsAndFillFormulas) with

Macros In: >>> Shows >>>> All Open Workbooks
All I see are my several
personal.xls!abc
personal.xls!def
personal.xls!hij
personal.xls!klm

This has never happen; I've been trying to correct this for over an hour; I
need help
Any Ideas????
TIA..
 
The sub requires an argument, so it doesn't appear in the macro list.
(since it requires an argument it would be inappropriate to select it in the
list and hit run).
 
Just to add:

Even though the argument is listed as optional, since an argument is listed,
it still does not show. If you don't need to use an argument, remove the
argument in the definition and adjust for it within the sub as well (if
necessary).
 
Trying to follow your suggestions,,, I've concluded that "I'm in a bit over
my head"..
I couldn't put my cursor on the Button/Macro necessary to get into my system
to activate the InsertRowsAndFillFormulas procedure.
Tks,
JMay
 
Hi J.....,
While in customize you cannot copy a button from a webpage
or the spreadsheet you have to that outside of customize. So...

Before starting right-click on the button on the webpage you want
to use then choose "Copy" from the context (Right-click) menu.
The buttons I use are listed at:
http://www.mvps.org/dmcritchie/excel/toolbar.htm#xl2kTBM

You want to get into customize, right-click on an empty area
in the menu / toolbars area or use Tools, Customize
everything below is done from customize, if you hit the [x] to
close customize you are out of customize.

Next install a toolbar, for your own macros you could add to another
toolbar, but it would be better to start your own toolbar.
From customize: choose the Toolbars Tab, then the [New] button
and name your toolbar "Custom 1" is fine. You will see the toolbar
floating on the spreadsheet area drag it up to the toolbar area.
http://www.mvps.org/dmcritchie/excel/toolbar.htm#addtoolbar

Once you have installed the toolbar, install the generic smileyface
button marked "Custom Button" to your toolbar that you created
From customize: choose the Commands Tab, then on the left
go down to "Macros", then on the right choose the one with the
smileyface marked "Custom Button" and drag it to your toolbar.
Right-click on the toolbar icon to assign a description, and to assign a macro.
http://www.mvps.org/dmcritchie/excel/toolbar.htm#addicon

Next still in customize, to customize your buttonface image. You
can chose a builtin button face or you can paste your own picture
over the smileyface. (If you don't have an image copied to the
clipboard, you will have to exit customize, copy your picture which
is preferable 12x12 pixels, then return to customize).
Right-click on the toolbar icon and make your choice,
Paste button image, Change Button image, Edit button image.
http://www.mvps.org/dmcritchie/excel/toolbar.htm#custom

BTW, I install my macros in my personal.xls workbook, so it is always
available. You noted that you created a workbook just for the macro.

Even if you mark the optional argument with a value you still have to
type in the macro name in Alt+F8 The macro could start with
Sub InsertRowsAndFillFormulas(Optional vRows As Long = 1)
the fact that it has a parameter is the deciding factor not that it may
need a value. As Tom indicated you can drop the optional parameter
altogether and them DIM your vRows variable.

Once you've done it, would appreciate it if you can help with the wording
in my toolbars.htm to avoid the stumbling block that you encountered.
Email would be better if you have lots of changes.

HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm
 
Dave:
Thanks for the welcomed reply; It's a bit late to undertake all this
tonight - I'll do it tomorrow + gladly assist in clarifying "my" reasons for
fumbling through.." for others who come along. You have supplied a wealth
of material, of which, we all are extremely appreciative.
Tks,
JMay

David McRitchie said:
Hi J.....,
While in customize you cannot copy a button from a webpage
or the spreadsheet you have to that outside of customize. So...

Before starting right-click on the button on the webpage you want
to use then choose "Copy" from the context (Right-click) menu.
The buttons I use are listed at:
http://www.mvps.org/dmcritchie/excel/toolbar.htm#xl2kTBM

You want to get into customize, right-click on an empty area
in the menu / toolbars area or use Tools, Customize
everything below is done from customize, if you hit the [x] to
close customize you are out of customize.

Next install a toolbar, for your own macros you could add to another
toolbar, but it would be better to start your own toolbar.
From customize: choose the Toolbars Tab, then the [New] button
and name your toolbar "Custom 1" is fine. You will see the toolbar
floating on the spreadsheet area drag it up to the toolbar area.
http://www.mvps.org/dmcritchie/excel/toolbar.htm#addtoolbar

Once you have installed the toolbar, install the generic smileyface
button marked "Custom Button" to your toolbar that you created
From customize: choose the Commands Tab, then on the left
go down to "Macros", then on the right choose the one with the
smileyface marked "Custom Button" and drag it to your toolbar.
Right-click on the toolbar icon to assign a description, and to assign a macro.
http://www.mvps.org/dmcritchie/excel/toolbar.htm#addicon

Next still in customize, to customize your buttonface image. You
can chose a builtin button face or you can paste your own picture
over the smileyface. (If you don't have an image copied to the
clipboard, you will have to exit customize, copy your picture which
is preferable 12x12 pixels, then return to customize).
Right-click on the toolbar icon and make your choice,
Paste button image, Change Button image, Edit button image.
http://www.mvps.org/dmcritchie/excel/toolbar.htm#custom

BTW, I install my macros in my personal.xls workbook, so it is always
available. You noted that you created a workbook just for the macro.

Even if you mark the optional argument with a value you still have to
type in the macro name in Alt+F8 The macro could start with
Sub InsertRowsAndFillFormulas(Optional vRows As Long = 1)
the fact that it has a parameter is the deciding factor not that it may
need a value. As Tom indicated you can drop the optional parameter
altogether and them DIM your vRows variable.

Once you've done it, would appreciate it if you can help with the wording
in my toolbars.htm to avoid the stumbling block that you encountered.
Email would be better if you have lots of changes.

HTH,
David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

Trying to follow your suggestions,,,
I couldn't put my cursor on the Button/Macro necessary to get into my system
to activate the InsertRowsAndFillFormulas procedure.
 
Back
Top