Microsoft Office Forums

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 04-18-2013, 10:10 AM
Drizz Drizz is offline Auto message box on open (when using template) Windows 7 64bit Auto message box on open (when using template) Office 2010 64bit
Novice
Auto message box on open (when using template)
 
Join Date: Apr 2013
Posts: 4
Drizz is on a distinguished road
Default

Oh ok I hear ya. So I had this:

'-------- AUTOOPEN ---------------
Sub AutoOpen() 'runs when document is opened


'This name "AutoOpen" is a Visual Basic reserved name for launching
'code when a Word document is opened.
'AutoOpen works in Word 'Auto_Open works in Excel
MsgBox "Ensure that you get Manager authorization", vbOKOnly + vbInformation, "NOTE"
End Sub

Do you have any idea how I edit all that to what I need?
Reply With Quote
  #2  
Old 04-23-2013, 12:41 AM
OTPM OTPM is offline Auto message box on open (when using template) Windows 7 32bit Auto message box on open (when using template) Office 2010 32bit
Expert
 
Join Date: Apr 2011
Location: West Midlands
Posts: 981
OTPM is on a distinguished road
Default

Hi Drizz
Sorry for the late response as I have ben offline for a few days. I will have a look at your issue today and get back to you.
Tony
Reply With Quote
  #3  
Old 04-23-2013, 12:56 AM
OTPM OTPM is offline Auto message box on open (when using template) Windows 7 32bit Auto message box on open (when using template) Office 2010 32bit
Expert
 
Join Date: Apr 2011
Location: West Midlands
Posts: 981
OTPM is on a distinguished road
Default

Hi Drizz

Follow these steps:
1. Open your Normal.dotm template (NOT a document).
2. Create a Macro in a Module as follows:

Sub AutoExec() 'runs when document is opened
'This name "AutoExec" is a Visual Basic reserved name for launching
'code when a Word is opened.
MsgBox "Ensure that you get Manager authorization", vbOKOnly + vbInformation, "NOTE"
End Sub

3. Save your template and close it.
4. Open Word in the normal manner and the AutoExec Macro will run BEFORE any document is opened.

Bear in mind that this will only work on your version of the Normal.dotm template if it is stored locally. If you are using a networked version of the Template then create the macro in that copy of the template. If you want it to work on multiple machines then you must do the same for each machine.
Good luck.
Come back to the forum if you need further help.
Good luck.
Tony

Last edited by OTPM; 04-23-2013 at 06:47 AM.
Reply With Quote
Reply



Similar Threads
Thread Thread Starter Forum Replies Last Post
Message from template not saving nigh Outlook 0 01-11-2012 03:11 AM
Auto message box on open (when using template) Auto reply when receiving a specific message Emerogork Outlook 2 09-06-2011 06:35 PM
30 seconds to open an e-mail message Emerogork Office 0 07-21-2011 08:49 AM
Pop Up Message on Open Emma Samm Word 0 12-20-2010 02:38 PM
Can't Copy and Paste until new message is open tabletop Outlook 0 12-04-2009 11:38 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 07:25 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft