Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.newusers
|
|||
|
|||
Writing a macro that will exit a spreadsheet
Hi there.
I am designing a spreadsheet and have various macros running, print, save etc, allocated to buttons on the sheet. However I would like to have a macro that also exits the spreadsheet when I run it, unfortunately when I try and record the macro I exit ok but the macro doesn't record. Any tips please? |
#2
Posted to microsoft.public.excel.newusers
|
|||
|
|||
Writing a macro that will exit a spreadsheet
I'm no expert, still learning the macro stuff myself,.
This has worked for me though... also upon a button_click Command. this one saves first, then exits. Sub SaveClose() ActiveWorkbook.Save ActiveWorkbook.Close End Sub "Dave Doc" wrote: Hi there. I am designing a spreadsheet and have various macros running, print, save etc, allocated to buttons on the sheet. However I would like to have a macro that also exits the spreadsheet when I run it, unfortunately when I try and record the macro I exit ok but the macro doesn't record. Any tips please? |
#3
Posted to microsoft.public.excel.newusers
|
|||
|
|||
Writing a macro that will exit a spreadsheet
Absolutely fantastic ufo_pilot!!!
You're a star, thank you very much Dave Doc "ufo_pilot" wrote: I'm no expert, still learning the macro stuff myself,. This has worked for me though... also upon a button_click Command. this one saves first, then exits. Sub SaveClose() ActiveWorkbook.Save ActiveWorkbook.Close End Sub "Dave Doc" wrote: Hi there. I am designing a spreadsheet and have various macros running, print, save etc, allocated to buttons on the sheet. However I would like to have a macro that also exits the spreadsheet when I run it, unfortunately when I try and record the macro I exit ok but the macro doesn't record. Any tips please? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Closing File Error | Excel Discussion (Misc queries) | |||
Writing Macro for extracting info from other softwares | Excel Discussion (Misc queries) | |||
Prevent A Macro From Running If SpreadSheet is Filtered | Excel Worksheet Functions | |||
insert rows in excel spreadsheet via macro | Excel Worksheet Functions | |||
Run a macro when opening a spreadsheet | Excel Discussion (Misc queries) |