Hi
I have a one page document with bookmarks on it. I can do just
replacement of those bookmarks once. But if I want to do it several
times, my approach is as:
1, copy the document template on to clipboard,
2, do replacement of the bookmarks once,
3, paste the thing to the end of the document
4, go to step 1 till finished
I have problem in step 1 and 3. you help will be highly appreciated,
thank you.
Greg Maxey - 07 Nov 2005 02:14 GMT
I really have no clue what it is that you are trying to do. Maybe this
bookmark tool will be helpful:
http://gregmaxey.mvps.org/Bookmark_Tool.htm

Signature
Greg Maxey/Word MVP
See:
http://gregmaxey.mvps.org/word_tips.htm
For some helpful tips using Word.
> Hi
>
[quoted text clipped - 9 lines]
> I have problem in step 1 and 3. you help will be highly appreciated,
> thank you.
Doug Robbins - Word MVP - 07 Nov 2005 05:29 GMT
From where is the data coming that is going to be used to replace the
bookmarks? Maybe you should be using mailmerge and execute the merge to a
new document.

Signature
Hope this helps.
Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.
Doug Robbins - Word MVP
> Hi
>
[quoted text clipped - 9 lines]
> I have problem in step 1 and 3. you help will be highly appreciated,
> thank you.
YiShusen@gmail.com - 07 Nov 2005 20:16 GMT
Thank you Greg and Doug.
Could any of you just tell me how to copy a whole word document and
paste to the end of the same ducument?
Doug Robbins - Word MVP - 07 Nov 2005 22:29 GMT
ActiveDocument.Range.InsertAfter ActiveDocument.Range

Signature
Hope this helps.
Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.
Doug Robbins - Word MVP
> Thank you Greg and Doug.
>
> Could any of you just tell me how to copy a whole word document and
> paste to the end of the same ducument?
YiShusen@gmail.com - 08 Nov 2005 02:55 GMT
Thank you all for response. I figured it out myself. if you are
intereted what I did, plesr read:
Selection.WholeStory
Selection.Copy
while condition is true
replace bookmarks
Selection.EndKey Unit:=wdStory, Extend:=wdMove
Selection.Paste
end while
'undo the last paste
ActiveDocument.Undo
'move cursor up
Selection.TypeBackspace
'clean Clipboard******************
Dim MyData As DataObject
Set MyData = New DataObject
MyData.SetText ""
MyData.PutInClipboard
'end of clean Clipboard******************