• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 297
  • Last Modified:

excel v.b.a macro

Hello

At excel version 97 I could create a macro and run it from any excel file (if I used the special option when creating it), but I didn't have to open the file containg the macro.
However, in excel 2000  I have to open the file containing the macro I want to run.
Isn't there a way of running a macro created in excel 2000 without opening the file containg it.

Thanks in advance
Erez
0
erez_bat
Asked:
erez_bat
  • 3
  • 2
1 Solution
 
TimCotteeHead of Software ServicesCommented:
In excel 97 you probably placed all of your macros in  "Personal.xls" which is automatically loaded by default and the spreadsheet portion of this file is marked as hidden so not displayed. This allows your macro to be run regardless as this spreadsheet is always loaded when you run excel. You can still do this with excel 2000, either create a personal.xls in your default folder (this is set on the general tab of the tools,options dialog) or just record a dummy macro and change the "Store Macro In" combobox value to "Personal Macro Workbook". This will create a new Personal.xls which will be automatically loaded in future and your macros will then be available.
0
 
erez_batAuthor Commented:
In the second way you say to change the combo-box value,
but this combobox is not editable.(Or I might be reffering to another combo-box).
The combo-box I see in the macro windo prompts you to choose which macros to display:
Those on the current file/on all current workbooks  
However it is not editable.

0
 
TimCotteeHead of Software ServicesCommented:
If you click Tools, Macros, Record new macro in the middle of the dialog that is displayed is a check box and next to it a combo box, drop down the list and change the value from the default which is "This Workbook" to "Personal Macro Workbook" then the macro that you record is saved into this template workbook. If you always ensure that your macros are recorded/written/saved into this workbook then they will be available to all other workbooks that you open.
0
 
erez_batAuthor Commented:
o.k
but if i want to edit the macro and write script, than I am forbidden of doing it, because the file is hidden
Is it names personal.xls>
How can I show him (cancel the hidden status ?), so I can edit the macro ?
 

0
 
TimCotteeHead of Software ServicesCommented:
You just need to open the VB Editor: Tools, Macro, Visual Basic Editor (Or press Alt+F11) and the Personal.xls workbook is displayed in the project explorer, open the Modules folder displayed and double-click module1 where your recorded macro is placed. You can continue to modify or create new scripts here.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now