Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a macro that is processed using sub auto via a
hyperlink. Basically, if someone cick the hyperlink it will run the macro. All the processing is invisible. Now, when this marco is run by just clicking the excel application it will run invisible and end he application invisible. However, when this marco is processed using the hyperlink, it will process invisible, but at the end it will show the sheet that i use to create the marco. I have used application.quit or auto_close, however, they rerun the process again and again. I am not able to use any of the close statment to shut of the application one the macro ends. Basically, i do not want the user to see the excel application. thanks in advance |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Gloria,
I have used application.quit or auto_close, however, they rerun the process again and again. I am not able to use any of the close statment to shut of the application one the macro ends. Basically, i do not want the user to see the excel application. thanks in advance When your macro has finished its work, add Application.Quit as the last statement in the routine that is last executed before the macro reaches its end. You must make sure that all open workbooks are saved or closed (except the one with the macro) without saving before this will work though. To tell excel a workbook does not have to be saved when closing, use: Workbooks("Yourbooksname.xls").Close SaveChanges:=False Or alternatively set: Workbooks("Yourbooksname.xls").Saved=True This will tell Excel to forget whether any change has been made to a workbook and it will close it without prompting for a save when you quit Excel. Regards, Jan Karel Pieterse Excel MVP www.jkp-ads.com |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Macro to quit application | Excel Discussion (Misc queries) | |||
Excel application.quit in macro problem | New Users to Excel | |||
macro to close excel application other than application.quit | Excel Programming | |||
Macro to quit excel and go back to original application | Excel Programming | |||
Using Application.quit is causing my macro to run and print twice... | Excel Programming |