Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

wordobj??? How do i switch this on 1

Status
Not open for further replies.

Donny

Technical User
May 3, 2001
19
0
0
US
I have some code that sets an [event procedure] for a command button to find a word file and open it. The code is as follows-
Private Sub Command1053_Click()
Dim wordobj As Word.Application
On Error GoTo ErrHandler
Set wordobj = GetObject(, "Word.Application")
wordobj.Application.Visible = True
wordobj.Documents.Open ("I:\MGM\CST\SITEWRKS\FORMS\isolations Database\TBQ - QUOTATION.doc")
Exit Sub
ErrHandler:
Set wordobj = CreateObject("Word.Application")
Resume Next
End Sub


Access fails to compile wordobj and i have forgotten how to swith it on....

Please help if you can


 
Donny,

Open your code window, go to Tools > References then check the Microsoft Word 8.0 library.....should sort it.

Craig
 
Craig

Cheers mate

perfect

Donny
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top