Repaint not working

scottrie2

Registered User.
Local time
Today, 16:14
Joined
Dec 27, 2018
Messages
15
I have an unbound form. There are two text boxes on the form, one for TotalRecords and the other for CurrentRecord. When I click the start button a process starts where I append records to a table (that part is working fine). Since this process can take a long time (10 minutes or so), I want to let the user know that the system is still working on processing. I have a counter that moves through the recordset that should tell the user what record is being worked on. I am using the command Me.Repaint before the loop and then within the loop of records that should display what record is being processed. The problem is that it will work for the first 5 or so records, but then it stops refreshing or repainting the form. Any ideas? I am open for a different approach as well.
 
Hi. Can you post the code? Thanks.
 
I tested setting value of a textbox inside a loop. Did not use Repaint. It works. Might post your code for analysis or provide db by following instructions at bottom of my post.

Could just change the cursor to Hourglass before process and then change back to normal after.

DoCmd.HourGlass True

DoCmd.HourGlass False
 
add DoEvent on your code. this will allow access to update any events in buffer.
 

Users who are viewing this thread

Back
Top Bottom