Simon,
When your add in is loaded, there is a OnConnection method I believe,
where you set a reference to the application that is hosting your add in.
When that is called, you should be able to hook into the events for the word
application (you need to cast it to a Word application instance, not just
the generic office application instance passed in). You should be able to
hook into the NewDocument event on the application object to be notified
when new documents are created.
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
-
mv*@spam.guard.caspershouse.com
"Simon" <si*********@hotmail.com> wrote in message
news:11**********************@z14g2000cwz.googlegr oups.com...
Hi,
I've used the wizzard in Visual Studio 2003 to create a Com Add-in for
word. When word runs it opens a blank document. How can i refrence that
document. I know how to open a new document and save it. But I want to
be able to do this with the current page that gets opened.
Any ideas? Am I making sense? I'm a bit new to this, sorry.
Thank you in advance,
Simon.