Hi all,

I am trying to write a script to copy something from Excel, switch to a Word file, search for a unique bit of text such as "paste_here" and then overwrite that text with the pasted data from excel.

The data to be copied can be either the cell or the value, I don't mind.

Can someone help me?

At the moment I have this for the copy/paste but I need to move the cursor to the "paste_here" bit.


Private Sub CommandButton1_Click()
Dim WordApp As Object
Dim WordDoc As Object


      Set WordApp = GetObject(, "Word.Application")

   Set WordDoc = WordApp.ActiveDocument

  
WordApp.Visible = True

Range("A1:C5").Copy

'needs something here to move to a unique piece of text = "paste_here"

WordApp.Selection.Paste


Set WordDoc = Nothing
Set WordApp = Nothing
End Sub
I was thinking about using a Find (and/or replace), which usually moves the cursor, but I cannot get that to work. Any help?

Thanks.