Reputation: 3529
I think the subject says it all, I'm trying to open a console (really just for debugging, to write object properties) from an Outlook Addin I wrote in C#. If so, how would you go about it? I tried starting a new console project just to see how it did it, but can't really see an easy way about it.
any thoughts are much appreciated! Thanks
Upvotes: 0
Views: 638
Reputation: 7886
If my understanding is correct in your Outlook addin cant you have some code like
System.Diagnostics.Process.Start(filename);
The above code is to invoke the appropriate file for opening. If the file name is of an exe then i guess it should open your console app.
UPDATE: You can include an console app that has the Main method as follows:
static void Main(string args[])
{
Console.Write(args[0].ToString());
Console.Read();
}
And now in your Load method of the outlook addin :
private void ThisAddIn_Startup(object sender, System.EventArgs e)
{
System.Diagnostics.Process.Start(filename, "hello test");
}
Now when your addin loads the console app should fire up and then print "hello test" in the console.
Upvotes: 2