E
eholz1
Hello Group,
I am trying to set a doc style from an excel macro to a word document.
I can set the style with "in-line" code, but cannot set the style (get
an "object" does not exist error)
from a sub procedure. I can move down in the word doc from a sub
procedure but it seems I cannot set the style for a line (like "Header
3", etc) Below is the sub procedure - what am I missing? I pass the
doc object and the application object.
Sub SelectBookMarkPlace(wApp As Word.Application, nCount As Integer)
With wApp.Selection
.MoveDown Unit:=wdParagraph, Count:=nCount, Extend:=wdMove
'.Style = thisDoc.Styles("Header 3")
End With
End Sub
thanks,
eholz1
I am trying to set a doc style from an excel macro to a word document.
I can set the style with "in-line" code, but cannot set the style (get
an "object" does not exist error)
from a sub procedure. I can move down in the word doc from a sub
procedure but it seems I cannot set the style for a line (like "Header
3", etc) Below is the sub procedure - what am I missing? I pass the
doc object and the application object.
Sub SelectBookMarkPlace(wApp As Word.Application, nCount As Integer)
With wApp.Selection
.MoveDown Unit:=wdParagraph, Count:=nCount, Extend:=wdMove
'.Style = thisDoc.Styles("Header 3")
End With
End Sub
thanks,
eholz1