![]() |
#7
|
||||
|
||||
![]()
Why are you trying to access Normal.dot through code? That makes no sense at all for what you said you want to do:
Quote:
Given that we're dealing with heading styles, you would only access Normal.dot to: • modify an existing Style, so that the change applies to all documents. But, since that would only be done once, you wouldn't use code; or • to ensure a current Style definition gets carried over to the document being opened. In that case, you might use code like: Code:
Private Sub Document_Open() With ActiveDocument Application.OrganizerCopy Source:=.AttachedTemplate.FullName, Destination:=.FullName, _ Name:=.Styles(wdStyleHeading2).NameLocal, Object:=wdOrganizerObjectStyles End With End Sub Depending on what you're trying to achieve, though, all you might need to do is to check the 'automatically update document styles' option.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
ubns | Word | 3 | 08-01-2012 09:42 PM |
![]() |
TheQueenBea | Word | 3 | 06-05-2012 12:12 PM |
![]() |
TheQueenBea | Word | 1 | 05-31-2012 02:22 PM |
![]() |
Jamal NUMAN | Word | 17 | 06-30-2011 05:47 PM |
How to have this Heading – Table of contents style? | Jamal NUMAN | Word | 0 | 01-13-2011 06:02 PM |