Dear Mr Excel,
I am building a spreadsheet which will use a progess bar on a userform to inform the user of the amount completed.
I would like to activate it from a button click within the spreadsheet(not on the userform) and whilst performing processing show the progress bar updating.
I have tried to do this but the operation performs first and then only a fully completed progress bar on the userform shows up after the operation is complete.
I need it to have the userform appearing firstly and updating at the same time as the operation is performing.
If you could advise me or provide some sample code, I would be very appreciative.
Attached is some sample code I am using as an example:
Private Sub UserForm_Initialize()
ProgressBar1.Min = 0
ProgressBar1.Max = 1000
For Count = 1 To 1000
ProgressBar1.Value = Count
'my code here
Sheets("Sheet1").Select
Range("A1").Select
ActiveCell = Count + 1
Next
End Sub
This message was edited by michaeldh on 2002-08-17 21:47
I am building a spreadsheet which will use a progess bar on a userform to inform the user of the amount completed.
I would like to activate it from a button click within the spreadsheet(not on the userform) and whilst performing processing show the progress bar updating.
I have tried to do this but the operation performs first and then only a fully completed progress bar on the userform shows up after the operation is complete.
I need it to have the userform appearing firstly and updating at the same time as the operation is performing.
If you could advise me or provide some sample code, I would be very appreciative.
Attached is some sample code I am using as an example:
Private Sub UserForm_Initialize()
ProgressBar1.Min = 0
ProgressBar1.Max = 1000
For Count = 1 To 1000
ProgressBar1.Value = Count
'my code here
Sheets("Sheet1").Select
Range("A1").Select
ActiveCell = Count + 1
Next
End Sub
This message was edited by michaeldh on 2002-08-17 21:47