Originally posted by kedaniel
Hi, what is the proper code to open a specific word document by clicking a button on a form?
The code generated by the wizard to open Word (no doc option), is:
Set oApp = CreateObject("Word.Application")
I am not getting any automatic suggestions if typing oApp. or putting commas behind the first sentence.
In order to see the automatic suggestions you have to set a reference to the "Microsoft Word Object Library"... (Make sure a module is open, go to the Tools menu... Select Tools -> References ...and add a check mark next to "Microsoft Word 9.0 Object Library" - could be 8.0, 10.0, etc... depending on what version of Word you are running)
As for opening the document... add the following line...