Re: Application-wide Objects in Windows Forms Apps
- From: Jack Jackson <jjackson@xxxxxxxxxxxxxxxx>
- Date: Sun, 05 Oct 2008 19:52:28 -0700
On Sun, 5 Oct 2008 14:11:00 -0700, Alex Maghen
<AlexMaghen@xxxxxxxxxxxxxxxx> wrote:
Let's say I have a Windows Forms app (.exe) and it has several Forms. How can
I create an object that is automatically accessible "globally" (to all Forms,
Classes, etc. running in the application)? Does such a Global space exist in
a Windows Forms Application?
Thanks.
Alex
There are several ways to do this.
1. Build a class with static (Shared in VB) methods and properties.
2. Build a class that is instantiated only once (Singleton).
.
- References:
- Application-wide Objects in Windows Forms Apps
- From: Alex Maghen
- Application-wide Objects in Windows Forms Apps
- Prev by Date: Re: Application-wide Objects in Windows Forms Apps
- Next by Date: RE: Application-wide Objects in Windows Forms Apps
- Previous by thread: Re: Application-wide Objects in Windows Forms Apps
- Next by thread: RE: Application-wide Objects in Windows Forms Apps
- Index(es):