TextBox Question!

  • Thread starter Thread starter Bob
  • Start date Start date
B

Bob

Can I get a text box to show"Overdue Amount " when this text
box(tbOverDueAmount) shows anthing more than zero


Thanks in advance.........Bob Vance




Thanks in advance.........Bob Vance
 
Bob said:
Can I get a text box to show"Overdue Amount " when this text
box(tbOverDueAmount) shows anthing more than zero

You mean you want some other text box to show the words "Overdue Amount"
if tbOverDueAmount is more than zero? YOu could give the text box a
controlsource expression of

=IIf([tbOverDueAmount > 0], "Overdue Amount", Null)
 
Dirk where do I put this script? Thanks Bob

Dirk Goldgar said:
Bob said:
Can I get a text box to show"Overdue Amount " when this text
box(tbOverDueAmount) shows anthing more than zero

You mean you want some other text box to show the words "Overdue Amount"
if tbOverDueAmount is more than zero? YOu could give the text box a
controlsource expression of

=IIf([tbOverDueAmount > 0], "Overdue Amount", Null)

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)
 
I did put this in Control Source Window and got a #Name? Error....Thanx Bob

Bob said:
Dirk where do I put this script? Thanks Bob

Dirk Goldgar said:
Bob said:
Can I get a text box to show"Overdue Amount " when this text
box(tbOverDueAmount) shows anthing more than zero

You mean you want some other text box to show the words "Overdue Amount"
if tbOverDueAmount is more than zero? YOu could give the text box a
controlsource expression of

=IIf([tbOverDueAmount > 0], "Overdue Amount", Null)

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)
 
Bob said:
Dirk where do I put this script? Thanks Bob

Dirk Goldgar said:
Bob said:
Can I get a text box to show"Overdue Amount " when this text
box(tbOverDueAmount) shows anthing more than zero

You mean you want some other text box to show the words "Overdue
Amount" if tbOverDueAmount is more than zero? YOu could give the
text box a controlsource expression of

=IIf([tbOverDueAmount > 0], "Overdue Amount", Null)

With the form open in design view, add the text box to be used for this
(if you haven't already). It will not be bound to any field. Then open
the property sheet for the text box, go to the Data tab, and enter the
expression (including the leading "=" sign) on the line that says
Control Source.
 
Oops still getting #Name? Maybe is it something to do what is in the other
Text box tbOverDueAmount
=NZ(DSum("OwnerPercentAmount","tblInvoice","OwnerID =" & tbOwnerID.Value & "
and InvoiceDate <" &
Format("Forms!frmBillStatement![tbDateFrom]","mm/dd/yyyy")),0)-NZ(DSum("PaidAmount","tblAccountStatus","OwnerID
=" & tbOwnerID.Value & " and BillDate <" &
Format("Forms!frmBillStatement![tbDateFrom]","mm/dd/yyyy")),0)

Thanks Bob

Dirk Goldgar said:
Bob said:
Dirk where do I put this script? Thanks Bob

Dirk Goldgar said:
Can I get a text box to show"Overdue Amount " when this text
box(tbOverDueAmount) shows anthing more than zero

You mean you want some other text box to show the words "Overdue
Amount" if tbOverDueAmount is more than zero? YOu could give the
text box a controlsource expression of

=IIf([tbOverDueAmount > 0], "Overdue Amount", Null)

With the form open in design view, add the text box to be used for this
(if you haven't already). It will not be bound to any field. Then open
the property sheet for the text box, go to the Data tab, and enter the
expression (including the leading "=" sign) on the line that says
Control Source.

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)
 
Sorry this is on a Report!!!
Bob

Dirk Goldgar said:
Bob said:
Dirk where do I put this script? Thanks Bob

Dirk Goldgar said:
Can I get a text box to show"Overdue Amount " when this text
box(tbOverDueAmount) shows anthing more than zero

You mean you want some other text box to show the words "Overdue
Amount" if tbOverDueAmount is more than zero? YOu could give the
text box a controlsource expression of

=IIf([tbOverDueAmount > 0], "Overdue Amount", Null)

With the form open in design view, add the text box to be used for this
(if you haven't already). It will not be bound to any field. Then open
the property sheet for the text box, go to the Data tab, and enter the
expression (including the leading "=" sign) on the line that says
Control Source.

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)
 
Bob said:
Oops still getting #Name? Maybe is it something to do what is in the
other Text box tbOverDueAmount
=NZ(DSum("OwnerPercentAmount","tblInvoice","OwnerID =" &
tbOwnerID.Value & " and InvoiceDate <" &
Format("Forms!frmBillStatement![tbDateFrom]","mm/dd/yyyy")),0)-NZ(DSum("
PaidAmount","tblAccountStatus","OwnerID
=" & tbOwnerID.Value & " and BillDate <" &
Format("Forms!frmBillStatement![tbDateFrom]","mm/dd/yyyy")),0)

Argh! I typed it wrong. <sigh> I'm having a bad week. Here's what
you should put in the Control Source:

=IIf([tbOverDueAmount] > 0, "Overdue Amount", Null)
 
Back
Top