Trying to automate a Visual Studio Form as first page of Word doc

D

Dale G

Hi, I’m using Visual Studio 2008 with Vista. I’m trying to create an accident
report form & use VS to Automate the info from the form to MS Word.

This form (Accident Report) will be 3 pages. (I’m trying to duplicate, as
close as I can to the pen to paper report that we currently use, which is a
Word doc).

I finished the form and wired it to automate to Word, that’s it.

Would it be possible to add my form to the existing word doc as the first
page?

I’ve tried this link, http://support.microsoft.com/kb/q285599/

But I can’t seem to make it work. The errors that occur are,

1). I can’t get this file to open.

oDoc = oWord.Documents.Open(FileName:="C:\ThreePagedocument.doc")

2). The following has a underline in squiggly Blue ???

wdCollapseEnd

wdCharacter

wdCollapseEnd

wdCharacter

wdLine

wdCollapseEnd

wdCharacter

Unload(Me)


Any suggestions on how to complete the report will Be appreciated.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top