OK lets try this again, the last post weny goofy.


I use GetTickCount for Timouts in some serial communication with instruments.

PHP Code:
  start GetTickCount
  
Do
    If (
GetTickCount start 2000Then
      MsgBox 
("Light Meter Response Timed Out, TestConnection")
      
TestConnection False
      mvarReady 
False
      
Exit Function
    
End If
    
InBuffer InBuffer objMeterComm.Input
  Loop Until 
(InStr(InBuffervbCr)) 
This gave a timeout of approx 2 seconds in VB6

I have to use the following code in .NET to get something anywhere close.

PHP Code:
    start GetTickCount
    
Do
      If (
GetTickCount start 20000000000Then
        MsgBox
("Light Meter Response Timed Out, TestConnection")
        
TestConnection False
        mvarReady 
False
        
Exit Function
      
End If
      
InBuffer InBuffer objMeterComm.Input
    Loop Until 
(InStr(InBuffervbCr)) 

Notice the very large number. Is this because .NET returns a larger variable type, and VB6 choped it off?

Any ideas?