Click here to Skip to main content
15,894,405 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: barcode reader Pin
Justin Perez25-Jan-08 3:14
Justin Perez25-Jan-08 3:14 
GeneralRe: barcode reader Pin
Paul Conrad25-Jan-08 3:56
professionalPaul Conrad25-Jan-08 3:56 
GeneralRe: barcode reader Pin
Dave Kreskowiak25-Jan-08 3:44
mveDave Kreskowiak25-Jan-08 3:44 
GeneralRe: barcode reader Pin
Paul Conrad25-Jan-08 3:55
professionalPaul Conrad25-Jan-08 3:55 
Questionproblem with basic timer in vb.net [modified] Pin
Chun224-Jan-08 19:48
Chun224-Jan-08 19:48 
GeneralRe: problem with basic timer in vb.net Pin
CKnig24-Jan-08 21:44
CKnig24-Jan-08 21:44 
GeneralRe: problem with basic timer in vb.net Pin
Chun225-Jan-08 5:36
Chun225-Jan-08 5:36 
GeneralRe: problem with basic timer in vb.net Pin
Dave Kreskowiak25-Jan-08 9:41
mveDave Kreskowiak25-Jan-08 9:41 
Out of all the Timers that come in the .NET Framework, the System.Windows.Forms.Timer class is about the worst when it comes to raising it's event on time. System.Timers.Timer is better, but can still be late. The System.Threading.Timer is the most accurate, but is also the hardest to use.

In any case, counting ticks of a timer is about the worst way you can implement this. You should be using a rather fast firing timer (accurate or not) and comparing the current time to the scheduled time of a process you need to launch, even if it's every one second.

If you're code is doing other things and the UI thread is blocked for longer than your Timer's Interval is set for, using anything but the Threading.Timer will result in your tick count not being accurate because the events cannot be processed until the UI thread is unblocked.

Another possible issue is something else running on the machine could be screwing with the O/S-based timers that the .NET Timer classes rely on. Be it bad hardware or an O/S problem.



A guide to posting questions on CodeProject[^]



Dave Kreskowiak
Microsoft MVP
Visual Developer - Visual Basic
     2006, 2007




Questionhow can calling command prompt ? [modified] Pin
break_day24-Jan-08 18:58
break_day24-Jan-08 18:58 
AnswerRe: how can calling command prompt ? Pin
Dave Kreskowiak25-Jan-08 3:41
mveDave Kreskowiak25-Jan-08 3:41 
QuestionFind text problem Pin
monsieur_jj24-Jan-08 16:14
monsieur_jj24-Jan-08 16:14 
GeneralRe: Find text problem Pin
Johan Hakkesteegt25-Jan-08 1:54
Johan Hakkesteegt25-Jan-08 1:54 
GeneralRe: Find text problem Pin
Luc Pattyn25-Jan-08 4:08
sitebuilderLuc Pattyn25-Jan-08 4:08 
GeneralStreamwriter Pin
Cedrickdeorange24-Jan-08 12:27
Cedrickdeorange24-Jan-08 12:27 
GeneralRe: Streamwriter Pin
John_Adams24-Jan-08 18:31
John_Adams24-Jan-08 18:31 
GeneralRe: Streamwriter Pin
Cedrickdeorange25-Jan-08 14:15
Cedrickdeorange25-Jan-08 14:15 
GeneralReading from a file and using Set methods Pin
Cory Kimble24-Jan-08 7:14
Cory Kimble24-Jan-08 7:14 
GeneralRe: Reading from a file and using Set methods Pin
pmarfleet24-Jan-08 9:29
pmarfleet24-Jan-08 9:29 
GeneralRe: Reading from a file and using Set methods Pin
Cory Kimble25-Jan-08 4:52
Cory Kimble25-Jan-08 4:52 
Generalcustom datagrid problems Pin
Smithers-Jones24-Jan-08 6:28
Smithers-Jones24-Jan-08 6:28 
GeneralRe: custom datagrid problems Pin
Paul Conrad24-Jan-08 6:55
professionalPaul Conrad24-Jan-08 6:55 
GeneralRe: custom datagrid problems [modified] Pin
Smithers-Jones24-Jan-08 10:12
Smithers-Jones24-Jan-08 10:12 
Question[Message Deleted] Pin
zeeshi_2424-Jan-08 0:50
zeeshi_2424-Jan-08 0:50 
GeneralRe: mpeg file encryption and compression...urgent!!!! Pin
Steven J Jowett24-Jan-08 2:03
Steven J Jowett24-Jan-08 2:03 
GeneralRe: mpeg file encryption and compression...urgent!!!! Pin
Vimalsoft(Pty) Ltd24-Jan-08 2:04
professionalVimalsoft(Pty) Ltd24-Jan-08 2:04 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.