Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.word.customization.menustoolbars,microsoft.public.word.docmanagement,microsoft.public.word.formatting.longdocs,microsoft.public.word.newusers
|
|||
|
|||
![]()
Hello,
Hope I can get some instruction on how to set a template so that the new document opens with the cursor located further on in the document at some book mark. I think maybe using a Go To comand in a macro that runs when the document starts, but I don't know how to do it... Please help if you have suggestions... Thanks! Raymond |
#2
![]()
Posted to microsoft.public.word.customization.menustoolbars,microsoft.public.word.docmanagement,microsoft.public.word.formatting.longdocs,microsoft.public.word.newusers
|
|||
|
|||
![]()
Insert a bookmark where you want the document to open. Lets call it
"OpenHere" Use something like: Sub AutoOpen() ActiveDocument.GoTo What:=wdGoToBookmark, Name:="OpenHere" 'or Dim oRng As Word.Range Set oRng = ActiveDocument.Bookmarks("OpenHere").Range oRng.Select End Sub Raymond (REMOVE) wrote: Hello, Hope I can get some instruction on how to set a template so that the new document opens with the cursor located further on in the document at some book mark. I think maybe using a Go To comand in a macro that runs when the document starts, but I don't know how to do it... Please help if you have suggestions... Thanks! Raymond |
#3
![]()
Posted to microsoft.public.word.customization.menustoolbars,microsoft.public.word.docmanagement,microsoft.public.word.formatting.longdocs,microsoft.public.word.newusers
|
|||
|
|||
![]()
Let's say you name the bookmark "StartHere". Then this code in the template
will place the cursor at the bookmark when a new document is created: Sub AutoNew() ActiveDocument.Bookmarks("StartHere").Range.Select End Sub The AutoNew macro name is special -- it runs automatically when a new document is created from the template (and not at any other time, unless you manually start it). -- Regards, Jay Freedman Microsoft Word MVP FAQ: http://word.mvps.org Email cannot be acknowledged; please post all follow-ups to the newsgroup so all may benefit. Raymond wrote: Hello, Hope I can get some instruction on how to set a template so that the new document opens with the cursor located further on in the document at some book mark. I think maybe using a Go To comand in a macro that runs when the document starts, but I don't know how to do it... Please help if you have suggestions... Thanks! Raymond |
#4
![]()
Posted to microsoft.public.word.customization.menustoolbars,microsoft.public.word.docmanagement,microsoft.public.word.formatting.longdocs,microsoft.public.word.newusers
|
|||
|
|||
![]()
This is great, just the thing i thought I should be looking for! Now i just
need to figure out how I put this code into my template. The only macros i've been able to devise have been by recording the keystrokes... Thanks so much for the info! Raymond "Jay Freedman" wrote in message ... Let's say you name the bookmark "StartHere". Then this code in the template will place the cursor at the bookmark when a new document is created: Sub AutoNew() ActiveDocument.Bookmarks("StartHere").Range.Select End Sub The AutoNew macro name is special -- it runs automatically when a new document is created from the template (and not at any other time, unless you manually start it). -- Regards, Jay Freedman Microsoft Word MVP FAQ: http://word.mvps.org Email cannot be acknowledged; please post all follow-ups to the newsgroup so all may benefit. Raymond wrote: Hello, Hope I can get some instruction on how to set a template so that the new document opens with the cursor located further on in the document at some book mark. I think maybe using a Go To comand in a macro that runs when the document starts, but I don't know how to do it... Please help if you have suggestions... Thanks! Raymond |