Author | Message | Time |
---|---|---|
DeSigN | any0ne g0t a g00d c0de for fl00dpr0tecti0n? its very c0nfusing, ive tried it ??? ::) | January 25, 2003, 9:32 PM |
Noodlez | [code] Dim delay As Double delay = (((Len(Data) * 15 + 1700) / 1000) + 1) * 1000 [/code] this is the algorithm i use, it will return the delay that you should use in miliseconds. then you would use CreateTimer() to make a timer with this delay and have it call your function to send the next message in queue. | January 25, 2003, 11:36 PM |
kamakazie | Isn't that the same thing as saying: [code] Dim delay As Double delay = Len(Data) * 15 + 2700 [/code] :-/ | January 26, 2003, 2:31 AM |
DeSigN | is createtimer a vb function? | January 26, 2003, 1:01 PM |
celluloid | if i get this right, Noodlez was just saying make a function somewhat like Createtimer() (the concept) | January 27, 2003, 12:32 AM |
Noodlez | Er, I meant SetTimer. Not Create. SetTimer is a function in user32.dll [code]Public Declare Function SetTimer Lib "user32" Alias "SetTimer" (ByVal hWnd As Long, ByVal nIDEvent As Long, ByVal uElapse As Long, ByVal lpTimerFunc As Long) As Long [/code] That's how you declare it. An example call would be: [code]SetTimer(Me.Hwnd,&H0,delay, AddressOf SendQueue)[/code] | January 27, 2003, 2:22 AM |