View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.setup
Gord Dibben Gord Dibben is offline
external usenet poster
 
Posts: 22,906
Default Load custom buttons in a Spreadsheet

Good to hear.

Thanks for the feedback

On Sat, 4 Oct 2008 12:21:24 +0100, Garrystone
wrote:


Thanks for your advice (which of course worked) with a small tweak (I
needed to dock the toolbar:top and not float).

Thanks again

Garry

Gord Dibben;733059 Wrote:
You must code to create the button when workbook opens, then delete the
button when it closes.

See Debra Dalgleish's site for creating a Toolbar with your button and
assign a macro to that button.

http://www.contextures.on.ca/xlToolbar02.html#Code

Note: the instructions found are for creating an add-in.

Just modify those instructions to place the code into a general module
in
the workbook the students are to use.


Gord Dibben MS Excel MVP


On Thu, 2 Oct 2008 12:10:33 +0100, Garrystone
wrote:
-

Hi
I know how to create a custom button and attach a macro to that

button
and that I can automatically load a button 'Private Sub
Workbook_Activate()' (Alt F11). Which I need to do because this
spreadsheet is used by many of my students (different profiles) and I
only want it available in a single spreadsheet file that they will
access. My problem lies in that each time I load this Spreadsheet a

new
button is placed on the toolbar (i.e. load 3 times, I end up with 3

new
buttons) and I can't seem to get the button to link to the macro
without it running the command and not waiting until the button is
pressed.
Can anybody help please as it is causing me much distress.

Thank you

Garry-