indy500fan
asked on
How do I maximize a form that is minimized (through code)
Friends,
I have a form that is running in the background (minimized), and it is listening to a TCP Stream (and consequently parsing the strings coming out of the stream). Now, when a valid string is found, and matches the criteria below, I want to maximize the screen. What is the syntax for maximizing a form?
Thanks in advance!
Btw, here is the code where, if the condition is met, the form would need to be maximized.
Case "F"
If PresentFlagState = Nothing Then
PresentFlagState = AMBParser_Flag.GetValue(AM BMLPValidS tring, 4)
Else
Dim TestForNewFlagState As String = Nothing
TestForNewFlagState = AMBParser_Flag.GetValue(AM BMLPValidS tring, 4)
If PresentFlagState = TestForNewFlagState Then
NewFlagStateFound = False
Else
NewFlagStateFound = True
PresentFlagState = TestForNewFlagState
End If
End If
If NewFlagStateFound = True Then
'Get Flag Detail
Select Case PresentFlagState
Case PresentFlagState = "Green"
AVAOMain.??? '<-This is where the form would need to be maximized.
Regards,
Eric
I have a form that is running in the background (minimized), and it is listening to a TCP Stream (and consequently parsing the strings coming out of the stream). Now, when a valid string is found, and matches the criteria below, I want to maximize the screen. What is the syntax for maximizing a form?
Thanks in advance!
Btw, here is the code where, if the condition is met, the form would need to be maximized.
Case "F"
If PresentFlagState = Nothing Then
PresentFlagState = AMBParser_Flag.GetValue(AM
Else
Dim TestForNewFlagState As String = Nothing
TestForNewFlagState = AMBParser_Flag.GetValue(AM
If PresentFlagState = TestForNewFlagState Then
NewFlagStateFound = False
Else
NewFlagStateFound = True
PresentFlagState = TestForNewFlagState
End If
End If
If NewFlagStateFound = True Then
'Get Flag Detail
Select Case PresentFlagState
Case PresentFlagState = "Green"
AVAOMain.??? '<-This is where the form would need to be maximized.
Regards,
Eric
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Sorry carl_tawn did not refresh before posting.
ASKER
Sorry Fernando, carl_tawn beat you to it. :)
No prob FernandoSoto, happens to us all ;o)
AVAOMain.WindowState = FormWindowState.Maximized
Fernando