Question about classes...
Posted on 2009-04-07
C# .NET 2008 - this is a Windows Based Application with multiple forms.
I have a class called AppSecurity that needs to be available in the application at any point in time. I do not need multiple instances of this class - simply one instance. Right now I am instantiating the class from a form. I fear that when I close this form I will end up losing the instance of my class.
Is there a way to create the class so that it does not have to be instantiated? Or is there someplace that I should be instantiating it so that it will be available at all times provided the program is in a runtime state?