-----------------------------------------------------------

New Message on MumbaiUserGroup

-----------------------------------------------------------
From: VishalRJoshi
Message 11 in Discussion

 Performance with static variables as compared to Application variables

Sometimes if you want to share a value of a type across pages then it is
sensible to use static variables instead of Application variable... The
advantages from performance perspective by taking this approach are:

Storing and reading a value can be many times faster with static variables
as they do not require to lookup into application variables collection when
you refer to them... 

You also do not need to cast from object to a specific type, as you need to
do with Application variables, but you need to make sure that you declare
the static variable of same type as the object that needs to be stored... By
this you can also avoid the overhead casting, boxing and unboxing... 
 
Vishal Joshi
Microsoft MVP .Net
       If You Think YOU CAN... You Can...
http://VishalJoshi.Blogspot.com 
http://www.microsoft.com/india/mvp/indiamvp.aspx 
http://groups.msn.com/ChennaiNetUserGroup
http://groups.msn.com/CNUG-DAM
http://groups.msn.com/NetBloomingtonUserGroup

PS: .Net-BUG Technical sessions re-started today after quite some time (we
still have been having Industry Sessions every month)...  A happy start for
community spirit in Bloomington, IL... 



-----------------------------------------------------------

To stop getting this e-mail, or change how often it arrives, go to your E-mail 
Settings.
http://groups.msn.com/MumbaiUserGroup/_emailsettings.msnw

Need help? If you've forgotten your password, please go to Passport Member Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help

For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact

If you do not want to receive future e-mail from this MSN group, or if you received 
this message by mistake, please click the "Remove" link below. On the pre-addressed 
e-mail message that opens, simply click "Send". Your e-mail address will be deleted 
from this group's mailing list.
mailto:[EMAIL PROTECTED]

Reply via email to