Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
So Hello,
I would like to save only the results of my sheets not the macro that generates it so I have done this: Sub workbook_open() Dim dtmSave As Date Dim dtmSave As Date OpenProgram 'Macro that open PackHedge Application.Cursor = xlWait ' Cursor in clock shape DoEvents On Error Resume Next dtmTime = Now + TimeValue("00:00:07") 'After seven seconds the macros has been launched Application.OnTime dtmTime, "thisworkbook.operations" 'Open the sub in thisworkbook Application.Cursor = xlDefault Application.DisplayAlerts = False Sheets(Array("Read Me", "File ", "Pages", "Values")).Copy ActiveWorkbook.SaveAs Filename:= _ "C:\test\test_save.xls", ReadOnlyRecommended:=False, CreateBackup:=False Application.DisplayAlerts = True dtmSave = dtmTime + TimeValue("00:00:30") Application.OnTime dtmSave, "thisworkbook.Save_Exit" End Sub .... My original file is test and I would like to have only the result in test1 and not in test. The trick is that I have the result in test and this code delete all the module of my test_save.xls and that's all. How can I do to delete the macro only and keep the result? i already try to do a macro in order (using vbcomponents) to delete it but didn't work. Ina |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Copy file with a macro | Excel Discussion (Misc queries) | |||
copy multiple worksheets of a workbook, and paste onto a Word document ( either create new doc file or paste onto an existing file.) I need this done by VBA, Excel Macro | Excel Programming | |||
VBA Macro to copy an column from one Excel file into another file | Excel Programming | |||
Macro Help...Copy form txt file | Excel Programming | |||
File Copy Macro | Excel Programming |