Try adding D.T.Appl.Save after the D.T.APPL.RUN macro run
D.T.APPL.RUN.... D.T.APPL.SAVE Or... you could add in a save into the macro itself? Thom C. Blackwell Vice President, Technical Services Boston Software Systems (866) 653-5105 ex 807 www.bossoft.com <http://www.bossoft.com/> Learn about what we do <http://www.youtube.com/watch?v=Fbjk_4LUZYU> Please follow us on Facebook <http://www.facebook.com/pages/Boston-Software-Systems/122739774403349?> and Twitter! <http://twitter.com/Bossoft> LEGAL NOTICE Unless expressly stated otherwise, this message is confidential and may be privileged. It is intended for the addressee(s) only. Access to this E-mail by anyone else is unauthorized. If you are not an addressee, any disclosure or copying of the contents of this E-mail or any action taken (or not taken) in reliance on it is unauthorized and may be unlawful. If you are not an addressee, please inform the sender immediately, then delete this message and empty from your trash. From: [email protected] [mailto:[email protected]] Sent: Wednesday, October 26, 2011 4:38 PM To: Talk Subject: [talkbws] Opening Excel Running a Macro in a script I opening a excel spreadsheet and running a macro in BWS then trying to process the post macro version of the spreadsheet. The macro runs but does not save the changes when I close and re-open the spreadsheet. I am sure that I have missed a command to save the changes in the script. Here is my code: Note I was trying to use a .bds file that has the post macro changes, I have tried a bds with and without the macro changes and it does not make a difference. (FILE OPEN STEP) D.Open_ "H:\BWS\AVEGA PROJECT\cost report INPUT.xls", ftExcel, "H:\BWS\AVEGA PROJECT\cost report revised REFORMATTED.xls.bds" (I see the spreadsheet layout in the data station) (MACRO STEP) D.T.APPL.RUN "PERSONAL.XLSB!MIDAS_AVEGA_COST_DATA_MACRO" (I can see my macro running and making changes to the workbook) D.CLOSE_ D.Open_ "H:\BWS\AVEGA PROJECT\cost report INPUT.xls", ftExcel, "H:\BWS\AVEGA PROJECT\cost report revised REFORMATTED.xls.bds" (I do not see the re-formatted layout in the data station window, just the original layout) When I look at the excel file no changes have been saved, I have a save in my macro. When I run the macro directly from the spreadsheet, it runs fine. Any help would be greatly appreciated. John Kamm Solution Development - Senior Analyst AHIS - St. John Providence Health System 28000 Dequindre Rd, Warren, MI 48092 Office - 586.753.1620 | Pager - 313.609.2874 --- To post a message to this list, send mail to: [email protected] You are currently subscribed as: [email protected] Unsubscribe in the customer center on our website: http://www.bostonworkstation.com/customer_center/virtual_user_group_talk .aspx CONFIDENTIALITY NOTICE: This email message and any accompanying data or files is confidential and may contain privileged information intended only for the named recipient(s). If you are not the intended recipient(s), you are hereby notified that the dissemination, distribution, and or copying of this message is strictly prohibited. If you receive this message in error, or are not the named recipient(s), please notify the sender at the email address above, delete this email from your computer, and destroy any copies in any form immediately. Receipt by anyone other than the named recipient(s) is not a waiver of any attorney-client, work product, or other applicable privilege. --- To post a message to this list, send mail to: [email protected] You are currently subscribed as: [email protected] Unsubscribe in the customer center on our website: http://www.bostonworkstation.com/customer_center/virtual_user_group_talk.aspx
