Hi,
I am populating book-marked documents via VBA. Have a problem however:
I have the following:
Set Mydoc2 = WordApp.Documents.Open(Attach_2)
Worksheets("CEM_Contract").Visible = True
Range("x").Copy
Mydoc2.Bookmarks("y").Range.PasteSpecial
Call Mydoc2.SaveAs(ThisWorkbook.Path & "\xxx.doc", , , , , , vbReadOnly)
Mydoc2.Application.Quit
then:
Mydoc = WordApp.Documents.Open(document)
etc..
I get an error. It complains that the remote server is not accessible or something like this.. I think it's bc of the last line up there... (mydoc2.app.quit).
So, what do I do in this case??!!
How do I work with 2 or 3 different documents that are book-marked?!
I am desparately in need of help.. Please!!
Anna
I am populating book-marked documents via VBA. Have a problem however:
I have the following:
Set Mydoc2 = WordApp.Documents.Open(Attach_2)
Worksheets("CEM_Contract").Visible = True
Range("x").Copy
Mydoc2.Bookmarks("y").Range.PasteSpecial
Call Mydoc2.SaveAs(ThisWorkbook.Path & "\xxx.doc", , , , , , vbReadOnly)
Mydoc2.Application.Quit
then:
Mydoc = WordApp.Documents.Open(document)
etc..
I get an error. It complains that the remote server is not accessible or something like this.. I think it's bc of the last line up there... (mydoc2.app.quit).
So, what do I do in this case??!!
How do I work with 2 or 3 different documents that are book-marked?!
I am desparately in need of help.. Please!!
Anna