send macros with file

A

Aimee

Hi all,

I am new to using macros, so forgive me if this question
is elementary.

I've created a program/file using Excel 2000 that allows
the user to paste objects onto a page by choosing the
object from a toolbar. This enables the user to customize
the pages. The objects on the toolbar have macros
connected to them allowing for the objects to be copied
from a hidden worksheet and then pasted onto the selected
page.

Sheets("Word Datasheets").Visible = True
Sheets("Word Datasheets").Select
ActiveSheet.Shapes("objBrightness").Select
Selection.Copy
Sheets("Word Datasheets").Visible = False
Sheets("Datasheets").Select
ActiveSheet.Paste

My problem is that users with other computers are not able
to use the toolbar macros. I have tried emailing the file
and also tried copying it onto a disk, but the macros are
not present when the other users open the file.

Is there a way to copy the macros with the file, or
another way to make the macros appear? Any help would be
greatly appreciated.
 
T

Tom Ogilvy

Macros are contained in a workbook. If you email the workbook, then the
macros originally in that workbook should be present. This assumes they are
using xl97 or later.
 
F

Frank Stone

aimee,
I'm not all that sure but i think custom tool bars are
machine specific and not file specific. you may have to
to create the tool bar on thier machines. I am having the
same problem in access.
frank.
 
P

PC

Hi Aimee,

Not sure what you mean when you say "My problem is that users with other
computers are not able
to use the toolbar macros". Do you mean the toolbar objects are not
present or that the underlying code is not present?

If its the tool bar objects you will need to distribut the Excel9.xlb file
which is normally contained in "C:\Documents and
Settings\%Username%\Application Data\Microsoft\Excel. Everytime you make a
change to the menus in excel this file is updated so if you want to
distribute a custom menu you must distribute this file (Note it doesn't
matter what the file is called so long as the file is kept in the "Startup"
directory

If the code is save directly in the work book there is no reason why it
would be distributed with the file.

If all your users are on the same network one way you could do this would be
to create a central distribution point where you can copy you Excel9.xlb
file. You could go one further and create all your code in the personal.xls
file (personal.xls is a hidden macro workbook that is held in the same
directory as above under "Xlstart") and save this is the central startup
folder. You can then set this central folder to be the startup folder for
excel for all the users of the macros. This way you can change and update
your macros and the menu and these changes will be reflected in excel for
each user each time the start excel.

hth

...pc
 
Top