During this loop
Dim i
shouldstop = False
For i = 0 To sec
DoEvents
If shouldstop = True Then
Settings_Click (1)
End
Exit Function
End If
Sleep 1000
Text1.Text = "Väntar " & sec - i
Next
the cmdquit and cmdclose events wont fire when clicking close. The form is closed yes. But the program is not unloaded from memory. This behaviour only exist during this loop.
What to do?
Dim i
shouldstop = False
For i = 0 To sec
DoEvents
If shouldstop = True Then
Settings_Click (1)
End
Exit Function
End If
Sleep 1000
Text1.Text = "Väntar " & sec - i
Next
the cmdquit and cmdclose events wont fire when clicking close. The form is closed yes. But the program is not unloaded from memory. This behaviour only exist during this loop.
What to do?