Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 81
Default Automatically Save and Route Code

I have a sheet that will be routed throughout a department. When
opened, it runs a macro that collects data. At the end of the
collection process, I'd like it to save, close and send to the next
receipient. However, if I set the macro to simply close the file, it
prompts the user to save then prompts to send.

Is there a way to skip these routing messages and just send it?

Any other hints on using Routing Slips in VBA code?

Thanks

- John

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 923
Default Automatically Save and Route Code

You could try something like this..... I assume the routing has already been
set up........put the code in ThisWorkBook module.

Private Sub Workbook_BeforeClose(Cancel As Boolean)
ActiveWorkbook.Route
Application.DisplayAlerts = False
ActiveWorkbook.Save
Application.DisplayAlerts = True
End Sub

--
Cheers
Nigel



"John Michl" wrote in message
oups.com...
I have a sheet that will be routed throughout a department. When
opened, it runs a macro that collects data. At the end of the
collection process, I'd like it to save, close and send to the next
receipient. However, if I set the macro to simply close the file, it
prompts the user to save then prompts to send.

Is there a way to skip these routing messages and just send it?

Any other hints on using Routing Slips in VBA code?

Thanks

- John



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
how to delete duplicate file example route 2_2:1 or route 2_2:2 Paul Excel Discussion (Misc queries) 5 October 8th 06 07:49 PM
Placing a code before Save & Save As Alex Martinez Excel Programming 1 September 27th 05 06:35 AM
How can I save an other route in my Tools bar-options-save? IT bazinoz Excel Discussion (Misc queries) 0 April 23rd 05 05:08 AM
When set to route, route with on open worksheet...not the hidden o Mike R. Excel Programming 0 December 20th 04 03:13 AM
Automatically run VB code on workbook save event Tim[_32_] Excel Programming 2 December 10th 03 08:06 PM


All times are GMT +1. The time now is 12:23 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"