A
Alan Stancliff
I have a WORD 2003 macro that uses the clipboard to do various things.
When the macro finishes, the clipboard contains a bit of the stuff the
macro put into it. I would like the macro to re-place whatc had
originally been in the clipboard. What I would like to have happen is this
****SEMI PSEUDO CODE****************
Sub DummyMacro()
' at beginning of macro copy
' clipboard material into variable
Dim myOriginalClipboardVariable as string
myOriginalClipboardVariable:= clipboard_contents
'
'Here macro does a bunch of stuff. A
'At the end of the macro, just before exiting
'clear the clipboard
clipboard:= ""
' then place stuff that was originally in the clipboard back
clipboard := myOriginalClipboardVariable
End Sub
******END SEMI PSEUDO CODE*********
I realize that this will not work as I have written it, but that's
because I am not yet familiar enough with VBA basics.
Would anyone mind giving me a hand here?
Regards,
Alan Stancliff
When the macro finishes, the clipboard contains a bit of the stuff the
macro put into it. I would like the macro to re-place whatc had
originally been in the clipboard. What I would like to have happen is this
****SEMI PSEUDO CODE****************
Sub DummyMacro()
' at beginning of macro copy
' clipboard material into variable
Dim myOriginalClipboardVariable as string
myOriginalClipboardVariable:= clipboard_contents
'
'Here macro does a bunch of stuff. A
'At the end of the macro, just before exiting
'clear the clipboard
clipboard:= ""
' then place stuff that was originally in the clipboard back
clipboard := myOriginalClipboardVariable
End Sub
******END SEMI PSEUDO CODE*********
I realize that this will not work as I have written it, but that's
because I am not yet familiar enough with VBA basics.
Would anyone mind giving me a hand here?
Regards,
Alan Stancliff