![]() |
#1
|
|||
|
|||
![]()
When a specific document is opened in Word, I want to open a particular Ribbon Tab Group.
I know how to do the second bit - make the Ribbon visible and open the required Tab Group - but how do I detect that the specific doument has been opened ? Is there an evet I can use, and where do I put the code ? |
#2
|
|||
|
|||
![]()
PS I don't want to make the document itself Macro-enabled, I want the Word environment to detect that it has been opened, if you see what I mean ?
|
#3
|
||||
|
||||
![]()
You can create a macro to run when every document is opened (see How to automatically execute a Word macro when you create, open, or close a document | TechRepublic
If you want the macro to only change the ribbon if one particular docx file is opened then you have two choices on how you might implement it: 1. Put the macro into a dotm template and attach that template to the docx 2. Code the macro to check the filename/path and only do anything if it matches your condition.
__________________
Andrew Lockton Chrysalis Design, Melbourne Australia |
#4
|
|||
|
|||
![]()
Thank you - I will work on that 😀
|
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Add text to beginning of new document opened from original Word document, with styles | ctviggen | Word VBA | 4 | 02-04-2024 08:31 AM |
Detecting that previous character doesn't exist (i.e., present character is first in document) | Robert K S | Word VBA | 15 | 08-01-2016 09:33 AM |
Document saved but cannot be opened. | N. Merrett | Word | 0 | 01-13-2016 05:41 PM |
Cannot select my custom tab when new document is opened | seamus59 | Word VBA | 0 | 03-19-2014 12:21 PM |
Detecting Who Opened in Email In Shared Folder | jerem | Outlook | 0 | 03-20-2010 10:58 AM |