PDA

View Full Version : VBA Script to open macro dialog box



naris
07-22-2008, 03:16 AM
Dear Everyone,

I need a script to open excel macro dialog box from excel VBA and than I can choose any macro from there, anyone can help me to give the excel VBA script ? ...

Thanks you very much before,
Naris

ilyaskazi
07-22-2008, 03:43 AM
You can do this in Excel by pressing ALT+F8 key and then select your macro to run...

naris
07-22-2008, 03:52 AM
Thanks you for your advice, but I need open the macro dialog box from excel macro script, could you help me ? ...

Thanks,
Naris

Bob Phillips
07-22-2008, 03:54 AM
Why?

david000
07-22-2008, 11:02 AM
Application.Dialogs(xlDialogRun).Show

naris
07-22-2008, 06:54 PM
I have a VBA project, and I will create the my VBA Project become excel addins, this excel addins, I will use to run a macro to all excel files and sheets in the one folder.

The Draft of addins ("Run Macro for All.xls") can run the macro properly because I writed the macro script in the VBA Editor ( Fill & Delete ).

But when I delete the macros ( Fill & Delete ) from my VBA project and save as addins (xla), I have a problem when I used the addins ("Run Macro for All.xla") in ?Macro to be run to all file.xls?.
My addins couldn't found the macro ("Fill & Delete ") which will be run to all workbooks & sheets in a folder ("Folder File")

I think I can used with directly to selected the macro from Run Macro Dialog Box, and I already tried with this way but the result didn?t useful.

Could you help me, give idea or what I have to do for it ? ?


Thanks,
Naris

rasamahaster
07-23-2008, 12:54 PM
Hi, I have a problem
If UserForm is open I can't open file Excel!
Why?

naris
07-23-2008, 06:35 PM
In my Run Macro for All.xls file, I a have plan to run macro fill or delete by the form to all workbook in Folder file with criteria ?book*?, For run the form, you can run macro name ?Showing? after the form displayed you must type in column one ? book*? for criteria the file which will run the macro, and than in column two, you must type once macro name that you want run, example : Fill ( you will fill column C in all files in the folder with formula as ?=$A1*$B1 ) or delete ( you will delete all column C contain ), after you have type all column in form, you can press the command button, and the macro will work, in the first displayed dialog you must select the folder where you stored the files will run the macro ( ? Folder File?) and then click ?OK?, and than macro will run to all excel files in selected folder.

Thanks,
Naris