7
Answers

timers and threads

I have an application which collects parameters and then calls a very complex SQL SP. The process works perfectly.

I wanted to put in a timer so that I could have some measure of the progress of the process in real time. For this purpose, I created a timer object, instantiated it, and within in the timer_tick event I have a text box capture the strings generated indicating elapsed time.

This functionality works perfectly well - that is, I am able to compute elapsed time and display it "in real time" **** E X C E P T ***** when the call to the SQL SP is made. Something happens, and my timer_tick event, although it fires, does not display anything.

My test for this was to comment out the call to the SQL SP - and under this circumstance, it works. It is ONLY when their is a call to the external SQL SP that it does not work properly UNTIL AFTER THE SQL PROC TERMINATES AND, I IMAGINE, RETURNS CONTROL TO THE Visual Studio/ADO/C# application.

Is there a way to override what appears to be an "unknown" condition that prevents my timer from displaying its contents?

Answers (7)