hi all,
I did a search but couldn't find anything for the particular issue I am having.
I have a Word 2003 template which creates relative links in a base Word document to other documents that will be located in the same directory. It does this by gathering a list of links (signified by a specific font color and text combination (ie. purple and 'GP 99-99-99').
1. Moves base document from base path to working path so that it is not disturbed while editing is going on
Base Path: Z:\NewPublish\1Publish\GP000000_com.doc
Working Path: Z:\NewPublish\1Publish\working\GP000000_com.doc
2. Opens document and finds text 'GP 99-99-99' to be turned in to a link ().
3. Creates link with code: ActiveDocument.Hyperlinks.Add Anchor:=Selection.Range, Address:=sDocName, SubAddress:=""
where sDocName = GP999999.doc
When stepping through the code I can see that the links are created properly by manually editing the link and by using Alt-F9....{ HYPERLINK "GP999999.doc" }
5. Saves a temp file in path: Z:\NewPublish\1Publish\tempword8.doc
6. Copies temp file to : Z:\NewPublish\4Web\GP000000.doc
When I open the GP000000.doc document in it's destination folder and edit the hyperlink the link is now "working/GP999999.doc", but displays as { HYPERLINK "GP999999.doc" } when using Alt-F9. The path no longer works!
I can't for the life of me figure out where or why the working/ is being added to the link. I imagine it's some kid of setting in Word 2003. I didn't have this issue in Word 97 (no changes were made to the template code when upgrading to Word 03).
Please help.
Thanks
I did a search but couldn't find anything for the particular issue I am having.
I have a Word 2003 template which creates relative links in a base Word document to other documents that will be located in the same directory. It does this by gathering a list of links (signified by a specific font color and text combination (ie. purple and 'GP 99-99-99').
1. Moves base document from base path to working path so that it is not disturbed while editing is going on
Base Path: Z:\NewPublish\1Publish\GP000000_com.doc
Working Path: Z:\NewPublish\1Publish\working\GP000000_com.doc
2. Opens document and finds text 'GP 99-99-99' to be turned in to a link ().
3. Creates link with code: ActiveDocument.Hyperlinks.Add Anchor:=Selection.Range, Address:=sDocName, SubAddress:=""
where sDocName = GP999999.doc
When stepping through the code I can see that the links are created properly by manually editing the link and by using Alt-F9....{ HYPERLINK "GP999999.doc" }
5. Saves a temp file in path: Z:\NewPublish\1Publish\tempword8.doc
6. Copies temp file to : Z:\NewPublish\4Web\GP000000.doc
When I open the GP000000.doc document in it's destination folder and edit the hyperlink the link is now "working/GP999999.doc", but displays as { HYPERLINK "GP999999.doc" } when using Alt-F9. The path no longer works!
I can't for the life of me figure out where or why the working/ is being added to the link. I imagine it's some kid of setting in Word 2003. I didn't have this issue in Word 97 (no changes were made to the template code when upgrading to Word 03).
Please help.
Thanks