Show a balance in a textbox!

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

Bob Vance

On my form I have 3 currency text boxes that have the same table
[tblBalance]
[tb1[, [tb2], [tb3]
What I want is in theAfterUpdate of [tb1] I want to show the balance in
[tb3] of [tb1] minus from [tb2]
 
Hi Bob,

how are the 3 tables related? What are the relevant fields in each of
the tables?

Warm Regards,
Crystal

*
(: have an awesome day :)
*
 
Hi Crystal
Sorry 3 text boxs are the 3 fields in a single table
Thanks Bob
strive4peace said:
Hi Bob,

how are the 3 tables related? What are the relevant fields in each of the
tables?

Warm Regards,
Crystal

*
(: have an awesome day :)
*


Bob said:
On my form I have 3 currency text boxes that have the same table
[tblBalance]
[tb1[, [tb2], [tb3]
What I want is in theAfterUpdate of [tb1] I want to show the balance in
[tb3] of [tb1] minus from [tb2]
 
Hi Bob,

if [tb3] = [tb1]-[tb2], then you should not store it. You can calculate
it anytime.

in a query

field --> Balance: [fieldname1] - [fieldname2]

on a form or report:
ControlSource --> [controlname1] - [controlname2]


Warm Regards,
Crystal

*
(: have an awesome day :)
*


Bob said:
Hi Crystal
Sorry 3 text boxs are the 3 fields in a single table
Thanks Bob
strive4peace said:
Hi Bob,

how are the 3 tables related? What are the relevant fields in each of the
tables?

Warm Regards,
Crystal

*
(: have an awesome day :)
*


Bob said:
On my form I have 3 currency text boxes that have the same table
[tblBalance]
[tb1[, [tb2], [tb3]
What I want is in theAfterUpdate of [tb1] I want to show the balance in
[tb3] of [tb1] minus from [tb2]
 
oops, the ControlSource must start with =

ControlSource --> =[controlname1] - [controlname2]

where
controlname1 and controlname2 are Names of controls (not fieldnames)

if one of the controls may not have a value, wrap the reference with NZ
(null to zero)

ControlSource --> =nz([controlname1],0) - nz([controlname2],0)


Warm Regards,
Crystal

*
(: have an awesome day :)
*

Hi Bob,

if [tb3] = [tb1]-[tb2], then you should not store it. You can calculate
it anytime.

in a query

field --> Balance: [fieldname1] - [fieldname2]

on a form or report:
ControlSource --> [controlname1] - [controlname2]


Warm Regards,
Crystal

*
(: have an awesome day :)
*


Bob said:
Hi Crystal
Sorry 3 text boxs are the 3 fields in a single table
Thanks Bob
strive4peace said:
Hi Bob,

how are the 3 tables related? What are the relevant fields in each
of the tables?

Warm Regards,
Crystal

*
(: have an awesome day :)
*


Bob Vance wrote:
On my form I have 3 currency text boxes that have the same table
[tblBalance]
[tb1[, [tb2], [tb3]
What I want is in theAfterUpdate of [tb1] I want to show the balance
in [tb3] of [tb1] minus from [tb2]
 

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

Back
Top