Outlook Banter

Outlook Banter (http://www.outlookbanter.com/)
-   Add-ins for Outlook (http://www.outlookbanter.com/add-ins-outlook/)
-   -   VSTO C#: How do I declare an application scope variable? (http://www.outlookbanter.com/add-ins-outlook/97423-vsto-c-how-do-i.html)

Mark B[_2_] November 26th 09 05:05 AM

VSTO C#: How do I declare an application scope variable?
 
C#, VSTO, OL2007

How do I declare an application-scope variable that will last as long as the
user has Outlook open?

String myApplicationScopeString="test";

I want other class methods to read and write to it over its lifetime.


Dmitry Streblechenko November 29th 09 05:50 PM

VSTO C#: How do I declare an application scope variable?
 
As a member of the class that implements your add-in?

--
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-
"Mark B" wrote in message
...
C#, VSTO, OL2007

How do I declare an application-scope variable that will last as long as
the user has Outlook open?

String myApplicationScopeString="test";

I want other class methods to read and write to it over its lifetime.




Mark B[_2_] November 29th 09 09:40 PM

VSTO C#: How do I declare an application scope variable?
 
I guess ThisAddIn.cs then.


"Dmitry Streblechenko" wrote in message
...
As a member of the class that implements your add-in?

--
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
-
"Mark B" wrote in message
...
C#, VSTO, OL2007

How do I declare an application-scope variable that will last as long as
the user has Outlook open?

String myApplicationScopeString="test";

I want other class methods to read and write to it over its lifetime.






All times are GMT +1. The time now is 12:26 PM.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2006 OutlookBanter.com