Strange Form Behavior

kcwallace

Centurion
Joined
May 27, 2004
Messages
175
Location
Austin, TX
I have a form that loops through a file that could have 100,000 lines in it. Each line gets parsed and imported into a database, and functions perfectly. Unfortunately, it can take a significant amount of time to run the code.

I need to give the user some sort of indication that the application is functioning. I added a simple counter that updates after every record is loaded into the database, i.e.:

Visual Basic:
Label2.Text = "Loaded " & Cnt & " of " & RowCnt & " Records"
Label2.Update()

The label gets updated perfectly for approximately the first 1000 records. After that the form seems to lock up and appears to be "Non-Responsive". However, the app is still functioning. All the records get loaded into the database, and at the conclusion of the loop the label says, "Loaded 500 of 500 Records"

I also tried using a progress bar, but it yielded the same result.

Can someone clue me into what is wrong.

Thank you in advance
 
Back
Top