#1   Report Post  
bbc1
 
Posts: n/a
Default Open Close workbooks

HI I have a workbook that user's use to input changed data each day into
severval different worksheets, once data is entered they have to save it as
filename(date) what I need is a macro that will close the saved workbook and
re-open the original.
eg saved worksheet is tallysheet28-8-05 original workbook tallysheet
  #2   Report Post  
Ron de Bruin
 
Posts: n/a
Default

Hi bbc1

Look in the VBA for SaveCopyAs
Your origenal workbook stay open and a copy will be saved with the name you want

Dim wb As Workbook
Set wb = ActiveWorkbook
wb.SaveCopyAs "C:\" & wb.Name & " " & Format(Now, "dd-mm-yy h-mm-ss") & ".xls"


--
Regards Ron de Bruin
http://www.rondebruin.nl


"bbc1" wrote in message ...
HI I have a workbook that user's use to input changed data each day into
severval different worksheets, once data is entered they have to save it as
filename(date) what I need is a macro that will close the saved workbook and
re-open the original.
eg saved worksheet is tallysheet28-8-05 original workbook tallysheet



  #3   Report Post  
bbc1
 
Posts: n/a
Default

Thankyou that works great.

"Ron de Bruin" wrote:

Hi bbc1

Look in the VBA for SaveCopyAs
Your origenal workbook stay open and a copy will be saved with the name you want

Dim wb As Workbook
Set wb = ActiveWorkbook
wb.SaveCopyAs "C:\" & wb.Name & " " & Format(Now, "dd-mm-yy h-mm-ss") & ".xls"


--
Regards Ron de Bruin
http://www.rondebruin.nl


"bbc1" wrote in message ...
HI I have a workbook that user's use to input changed data each day into
severval different worksheets, once data is entered they have to save it as
filename(date) what I need is a macro that will close the saved workbook and
re-open the original.
eg saved worksheet is tallysheet28-8-05 original workbook tallysheet




Reply
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
Excel closes all open apps when i close one ipctech Excel Discussion (Misc queries) 1 May 25th 05 12:04 AM
is it always necessary to open workbooks referenced in a formula levie Excel Discussion (Misc queries) 1 May 13th 05 12:14 AM
Macro that will add data from multiple workbooks to the 1st open r jbsand1001 Excel Discussion (Misc queries) 0 April 23rd 05 07:52 PM
Can you update links between workbooks without them both open? Nicolle K. Excel Discussion (Misc queries) 1 January 7th 05 07:39 PM
How can I close only 1 workbook when I have many open? jpt consulting Excel Discussion (Misc queries) 3 November 30th 04 11:58 PM


All times are GMT +1. The time now is 07:26 PM.

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

About Us

"It's about Microsoft Excel"