G
gouved
Try as I can to use suggestions, examples , etc. I cannot debug a macro to
get text generated within a bookmark to copy to the clipboard.
I set up a bookmark (not formfield) to contain references from my document
to generate a note:
(name ref) is (age calculation) y.o. (sex ref) (if statements) ---etc.
I usually copy the note manually after unprotecting the document, then paste
it in an access application (on a network) so I wrote the following:
Dim P_Status
With ActiveDocument
P_Status = .ProtectionType
If .ProtectionType <> wdNoProtection Then .Unprotect
.Bookmarks("Note").Value.Copy
If P_Status > -1 Then .Protect Type:=P_Status, Noreset:=True
End With
The compiler has a problem with the copy command, stating it needs an
object. I just don't see the problem.
Thanks.
get text generated within a bookmark to copy to the clipboard.
I set up a bookmark (not formfield) to contain references from my document
to generate a note:
(name ref) is (age calculation) y.o. (sex ref) (if statements) ---etc.
I usually copy the note manually after unprotecting the document, then paste
it in an access application (on a network) so I wrote the following:
Dim P_Status
With ActiveDocument
P_Status = .ProtectionType
If .ProtectionType <> wdNoProtection Then .Unprotect
.Bookmarks("Note").Value.Copy
If P_Status > -1 Then .Protect Type:=P_Status, Noreset:=True
End With
The compiler has a problem with the copy command, stating it needs an
object. I just don't see the problem.
Thanks.