Check Box to control Text Box

B

Bob V

I have a Check Box on my Main Form [Overdue, Yes/No]
I want this text box only to show on my report if [Overdue] is ticked
My text Box:
[tbOD] =IIf([tbOverDueAmount]>1,DLookUp("OverdueMessage","tblCompanyInfo"))

Thanks for any help.........Bob
 
G

Guest

In your checkbox's on change event put the following line of code:

me.yourtextbox.visible=me.yourcheckbox

Adam
 
B

Bob V

Thanks Adam but a check box does not have a On Change
event!............Thanks Bob

Adam Milligan said:
In your checkbox's on change event put the following line of code:

me.yourtextbox.visible=me.yourcheckbox

Adam


Bob V said:
I have a Check Box on my Main Form [Overdue, Yes/No]
I want this text box only to show on my report if [Overdue] is ticked
My text Box:
[tbOD]
=IIf([tbOverDueAmount]>1,DLookUp("OverdueMessage","tblCompanyInfo"))

Thanks for any help.........Bob
 
G

Guest

That line of code should also go in your form's on current event as well. It
is worth pointing out that if you uncheck the checkbox, only the text box
disappears. Any data will still be in the field/table.

Adam Milligan said:
In your checkbox's on change event put the following line of code:

me.yourtextbox.visible=me.yourcheckbox

Adam


Bob V said:
I have a Check Box on my Main Form [Overdue, Yes/No]
I want this text box only to show on my report if [Overdue] is ticked
My text Box:
[tbOD] =IIf([tbOverDueAmount]>1,DLookUp("OverdueMessage","tblCompanyInfo"))

Thanks for any help.........Bob
 
G

Guest

oops! I meant "After Update". Sorry.

Bob V said:
Thanks Adam but a check box does not have a On Change
event!............Thanks Bob

Adam Milligan said:
In your checkbox's on change event put the following line of code:

me.yourtextbox.visible=me.yourcheckbox

Adam


Bob V said:
I have a Check Box on my Main Form [Overdue, Yes/No]
I want this text box only to show on my report if [Overdue] is ticked
My text Box:
[tbOD]
=IIf([tbOverDueAmount]>1,DLookUp("OverdueMessage","tblCompanyInfo"))

Thanks for any help.........Bob
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Text Box Question 1
Report Text box dilemma 4
Make a text box return blank if 1
Combo Box to make visible 12
Visible Report code 10
Add to text box String 4
Stop Form from Opening 2
Check box teaser 2

Top