Help with updating label captions and statusbar panel text 
Author Message
 Help with updating label captions and statusbar panel text

This is a tough problem to explain, but here goes...

I am developing an application in VB4 and I need to change label captions
and statusbar panel text durring runtime to reflect the current status the
application.

The problem is that these captions and test change durring execution of an
event procedure e.g. a cmdButton1_Click() that is executed when Button1 is
clicked.

I basically have a For loop in the cmbButton_Click() proc that goes off and
does things "x" number of times and I need to reflect the status of this.

Durring execution of the cmdButton1_Click, the labels and statusbar panels
do not update until the procedure terminates.  When the procedure
terminates, the labels and panels are updated with their final values.  I
need to update them with values during execution of the procedure.

The real interesting thing is that I CAN update a progress bar while in the
For loop of my cmdButton1_Click proc!!!!!

Here is what I have done so far:
1.  Place the commands that update the labels and panel text in a seperate
procedure and call the procedure during each iteration of the For loop...No
Luck

2.  Try to use the InvalidateRect call to repaint the objects during each
iteration of the For loop...No Luck

Any help on this problem would be greatly appreciated.

Thanks

-Glenn Hess



Mon, 09 Aug 1999 03:00:00 GMT  
 Help with updating label captions and statusbar panel text

Do you have a DoEvents within the loop? If not, try it.


Quote:
>This is a tough problem to explain, but here goes...

>I am developing an application in VB4 and I need to change label captions
>and statusbar panel text durring runtime to reflect the current status the
>application.

>The problem is that these captions and test change durring execution of an
>event procedure e.g. a cmdButton1_Click() that is executed when Button1 is
>clicked.

>I basically have a For loop in the cmbButton_Click() proc that goes off and
>does things "x" number of times and I need to reflect the status of this.

>Durring execution of the cmdButton1_Click, the labels and statusbar panels
>do not update until the procedure terminates.  When the procedure
>terminates, the labels and panels are updated with their final values.  I
>need to update them with values during execution of the procedure.

>The real interesting thing is that I CAN update a progress bar while in the
>For loop of my cmdButton1_Click proc!!!!!

>Here is what I have done so far:
>1.  Place the commands that update the labels and panel text in a seperate
>procedure and call the procedure during each iteration of the For loop...No
>Luck

>2.  Try to use the InvalidateRect call to repaint the objects during each
>iteration of the For loop...No Luck

>Any help on this problem would be greatly appreciated.

>Thanks

>-Glenn Hess



Sun, 15 Aug 1999 03:00:00 GMT  
 Help with updating label captions and statusbar panel text

Quote:

> This is a tough problem to explain, but here goes...
> I am developing an application in VB4 and I need to change label captions
> and statusbar panel text durring runtime to reflect the current status the
> application.
> The problem is that these captions and test change durring execution of an
> event procedure e.g. a cmdButton1_Click() that is executed when Button1 is
> clicked.

[snip]

Look up Refresh.

--

WARNING: I cannot be held responsible for the above        They're   coming  to
because  my cats have  apparently  learned to type.        take me away, ha ha!



Sun, 15 Aug 1999 03:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. StatusBar date and time panels not updating

2. vb4: put tab chr(9) in label.caption or text box.text

3. Label.Caption/Text.Text question

4. Statusbar Panel Problem with the INS panel

5. statusbar panel text color

6. StatusBar text in Panels

7. Text exceeds statusbar panel width

8. Adding Picture AND Text to a StatusBar Panel

9. Update a Label.Caption

10. update of Label.Caption

11. label captions not updating

12. Updating label captions before a file copy

 

 
Powered by phpBB® Forum Software