Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to force to update a control in a sub-form? 1

Status
Not open for further replies.

sudakov

Programmer
Jun 17, 2007
53
US
Hello everyone,
I have a continuous sub-form within a form. The sub-form has a text-box control "TXB_AGGREGATE" that aggregates values (=SUM([FIELD1]) of a field in the sub-form.

If a user has not finished entering a new record in the sub-form (user does not move to a next record) the text-box control "TXB_AGGREGATE" is not updated with a value from the new record.

In many cases users do not move to a next record to save a new record in the sub-form. Instead they click on a button "BUTTON1" in the main-form. The button "BUTTON1" uses a value in the text-box control "TXB_AGGREGATE" in the sub-form which is not updated.

Does anybody know how to force to save a new record in the sub-form and to update the control "TXB_AGGREGATE" in the sub-form?
 
How are ya sudakov . . .

In your button code try:
Code:
[blue]   [[purple][b][i]YourSubformName[/i][/b][/purple]].Form.ReCalc[/blue]

See Ya! . . . . . .

Be sure to see thread181-473997 [blue]Worthy Reading![/blue] [thumbsup2]
Also faq181-2886 [blue]Worthy Reading![/blue] [thumbsup2]
 
Hi TheAceMan1,

it works like a charm!
Thank you!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top