Label Caption Change 
Author Message
 Label Caption Change

I'm trying to change a caption on a label using a "After Update" event
on a text box that's control source is  =nz([Quote
Subform].[Form]![Total],"0"). Formatted for "Currency"...  For the
life of me I can't get it to work..  

Is the problem that..
1) It's a calculating Text box
2) Being formatted for Currency

The code that I've tried is

If [Quote Total] < 10000# Then
        Label15.Caption = "Less than 120 Months"
   ElseIf [Quote Total] < 5000# Then
        Label15.Caption = "Less than 60 Months"
   End If

Any thoughts anyone???

Thanks
Grant Louis



Tue, 02 Nov 1999 03:00:00 GMT  
 Label Caption Change

Grant,

The text box's After_Update event will only be triggered if the user
enters a value there then presses 'Enter' or tabs out of box-see help.

make sure the After_Update event you are putting code into is actually
running by placing a break or using msgbox function.  Otherwise, be sure
you are correctly indicating the label (i.e. Forms!myform![Quote
Label].Caption).

Good luck,

Mark



Tue, 02 Nov 1999 03:00:00 GMT  
 Label Caption Change

Quote:

> Grant,

> The text box's After_Update event will only be triggered if the user
> enters a value there then presses 'Enter' or tabs out of box-see help.

> make sure the After_Update event you are putting code into is actually
> running by placing a break or using msgbox function.  Otherwise, be sure
> you are correctly indicating the label (i.e. Forms!myform![Quote
> Label].Caption).

> Good luck,

> Mark

Thanks Mark,

The text box only shows the result of the calculation.. should this be
in the "On Change" event?  I've really tried everything.. well... Not
everything
<G>

Any other ideas on how to do this?

Thanks
Grant



Tue, 02 Nov 1999 03:00:00 GMT  
 Label Caption Change

Quote:

> Grant,
> I would imagine the value of your text box does not change magically.
> There must be a value on the form that user changes that will trigger
> any event. I am speaking without specific reference to your controls as
> I can't find your original message. What event causes the value of txtX
> to change (possibly changing value in txtY--in that case use
> txtY_AfterUpdate).
> Good luck, have a nice weekend,
> Mark

Thanks Mark,
Got it work... I had the perameters in the If Statment wrong
... Dumb!

Best Regards,
Grant



Tue, 02 Nov 1999 03:00:00 GMT  
 Label Caption Change

Grant,
I would imagine the value of your text box does not change magically.
There must be a value on the form that user changes that will trigger
any event. I am speaking without specific reference to your controls as
I can't find your original message. What event causes the value of txtX
to change (possibly changing value in txtY--in that case use
txtY_AfterUpdate).
Good luck, have a nice weekend,
Mark



Tue, 02 Nov 1999 03:00:00 GMT  
 
 [ 5 post ] 

 Relevant Pages 

1. Auto label/Caption change

2. Change label caption in userform on change of dropdown listbox

3. Label Caption Doesn't Change When Changed

4. Permanently change a text label's caption?

5. Changing the caption property on a label at run time

6. Changing label captions: how to refresh

7. Change caption of a label in DataReport at runtime

8. Changing Label Captions on a Data Report.

9. Changing a Label caption

10. Changing label captions while running code

11. Change label.caption from a DLL.

12. Changing the caption property on a label at run time

 

 
Powered by phpBB® Forum Software