What am i doin wrong there?
Hello,
I have a code problem but im pretty new to vb so it might be a stupid question.
I have 1 module and 1 form in my test project. Here is what i put in the module:
Code:
Public Enum eeEnum
lThread = 1
lNoThread = 2
lerror = 3
End Enum
Public Enum eeTypeOut
lBOX
lPRINT
lNOTHING
End Enum
Public Enum tmrLoop
Everytime
Singletime
No
End Enum
Public Enum eeString
strue
sFalse
sYes
sNo
End Enum
Public Sub SESSION_TIMERLOOP(startPar As Long, _
endPar As Long, _
changePar As Long, _
declarebox As eeTypeOut, _
boxCap As String, _
boxInfo As String, _
boxType As VbMsgBoxStyle, _
tmrBox As tmrLoop _
)
Dim rloopIF As eeString
'Main timing
For i = startPar To endPar Step changePar
'Continue?
If declarebox = lBOX Then
If tmrBox = Everytime Then
MsgBox boxInfo & i, boxType, boxCap
ElseIf tmrBox = Singletime Then
If rloopIF = strue Then
'Display Message Box
MsgBox boxInfo & i, boxType, boxCap
rloopIF = sFalse
ElseIf rloopIF = sFalse Then
'No mesagebox
'cleanup
'SESSION_TIMERLOOP_CLEAN lThread
End If
End If
End If
'EndContinue c
Next
End Sub
Here is what i put into the form:
Code:
Private Sub Form_Load()
SESSION_TIMERLOOP "10", "100", "100", lBOX, "Information", "Counter: ", vbInformation, Everytime
End Sub
When is start it, it supost to return a message box with a value of ten. When i press OK, it should return a box with a value of 15. Next time 20 and so on. But that doesnt happend and the code stops when i get the first box with value of ten. When i press OK nothing else happends.
;) The project is not finished, so dont ask about extra values in enums