LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 15
Default Question about running macro from VBS

I am using the following script that will allow me to open up excel and run a
macro that is in it. It works fine but what I would like is that when it is
done, instead of asking me if I would like to just save the workbook It would
save the workbook with the data in cell B2 as the file name with the date
appended to the name in the same directory as the original workbook.

Here is what I am using right now. WhoMadeComments is the workbook name and
Get_Data is the macro

Set objXL = CreateObject("Excel.Application")
on error resume next

With objXL
.Workbooks.Open ("D:\Documents and
Settings\user\Desktop\testing\WhoMadeComments.xls" )
.Run "WhoMadeComments.xls!Get_Data"
.Quit
End With
Set objXL = Nothing
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Running Total Question Sam Excel Worksheet Functions 2 January 31st 12 11:27 PM
Running Sum question LisaK Excel Worksheet Functions 5 January 8th 08 11:59 PM
Running total question Mike Hyndman Excel Worksheet Functions 7 January 23rd 07 08:17 AM
running maximum (newbie question) [email protected] Excel Discussion (Misc queries) 7 May 22nd 06 02:13 AM
Running Macros question gifer Excel Programming 0 May 17th 05 04:06 PM


All times are GMT +1. The time now is 03:00 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"