D
Diego
Hi,
First of all, I am new with VSTO, so sorry for my unknowledge...
I have created an Office add-in (for Word & Excel) using Visual Studio 2005,
with C# (Extensibility - Shared Add-in.)
I have the created code, with the 'Connect' class:
public class Connect : Object, Extensibility.IDTExtensibility2
and I have the add in launch event in 'OnConnection()' method
I have 2 problems:
1. I need a 'opened document' event every time a word or excel document is
open. I have seen code samples to handle these events with methods like
private void ThisDocument_Startup(object sender, System.EventArgs e)
where 'ThisDocument' is the class name. But with my 'Connect' class it does
not work. I am really confussed, could anyone tell me what to do?
2. Every time a new document is open, I must get the creator, how can I
get the current document? Is it possible to do it in a generic way? I mean,
for excel & word documents.
I am not asking for the complete solution, just some steps to get my targets.
Thanks a lot in advance
Diego
First of all, I am new with VSTO, so sorry for my unknowledge...
I have created an Office add-in (for Word & Excel) using Visual Studio 2005,
with C# (Extensibility - Shared Add-in.)
I have the created code, with the 'Connect' class:
public class Connect : Object, Extensibility.IDTExtensibility2
and I have the add in launch event in 'OnConnection()' method
I have 2 problems:
1. I need a 'opened document' event every time a word or excel document is
open. I have seen code samples to handle these events with methods like
private void ThisDocument_Startup(object sender, System.EventArgs e)
where 'ThisDocument' is the class name. But with my 'Connect' class it does
not work. I am really confussed, could anyone tell me what to do?
2. Every time a new document is open, I must get the creator, how can I
get the current document? Is it possible to do it in a generic way? I mean,
for excel & word documents.
I am not asking for the complete solution, just some steps to get my targets.
Thanks a lot in advance
Diego