George Marsack
New member
Hello Everyone,
How do I create an event to watch when a Boolean variable changes values? Is this possible?
For example, I have a public function that is called to change a private shared variable, and I would like something hooked in to listen to when the private Boolean variable changes and fire off a function that would do something else when this occurred.
=====================================
Private Shared m_bLoadDefaults AsBoolean = False
Public Shared Sub LoadDefaults()
m_bLoadDefaults = True
End Sub
Private Sub SetDefaultStates()
'Stuff goes here.
End Sub
=====================================
Ideally, I would like to call the function, like MyClass.LoadDefaults() and what occurs next causes the event to be raised which fires off another function like SetDefaultStates().
Is this possible? Can anyone help me? I would really appreciate any feedback. I'm not very good with events and such and I'm very new at VB.NET. Thanks to anyone who can help.
--George
How do I create an event to watch when a Boolean variable changes values? Is this possible?
For example, I have a public function that is called to change a private shared variable, and I would like something hooked in to listen to when the private Boolean variable changes and fire off a function that would do something else when this occurred.
=====================================
Private Shared m_bLoadDefaults AsBoolean = False
Public Shared Sub LoadDefaults()
m_bLoadDefaults = True
End Sub
Private Sub SetDefaultStates()
'Stuff goes here.
End Sub
=====================================
Ideally, I would like to call the function, like MyClass.LoadDefaults() and what occurs next causes the event to be raised which fires off another function like SetDefaultStates().
Is this possible? Can anyone help me? I would really appreciate any feedback. I'm not very good with events and such and I'm very new at VB.NET. Thanks to anyone who can help.
--George