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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dynamic update of Text Box 2

Status
Not open for further replies.

errolf

IS-IT--Management
Aug 21, 2000
51
US
I am using a form as a General purpose switchboard for an application. One of the functions of the form is to update data from text files exported from another application. I am using a text box to display the date of the last update using the function =DMax("[INV_DATE]","SCEX").Unless I open and close the form after updating the table the date in the text box remains the same. How can I have the text box display the correct date without opening and closing the form after updating the table.Could the code in the update module be modified to do this?

Thanks in anticipation

Errol
 
How are ya errolf . . .

have a look at the [blue]Recalc[/blue] method! . . .

Calvin.gif
See Ya! . . . . . .
 
Thanks for the reply TheAceMan where do I find the Recalc method and how do I use it? I Tried it Using DoCmd.Recalc at the end of my update code but it returned "Method or data member not found"
Thanks for you help

Errol
 
where do I find the Recalc method and how do I use it?
The basic: in the debug window (Ctrl+G) type recalc and press the F1 key.
Another helpful key when in VBE is F2 (Object browser).

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Thanks PHY for the reply
I put "Me.Recalc" in the after update event code of the relevant Text box but it does not update the text box.
I must be missing the point somewhere.
Thanks and regards
Errol
 
errolf . . .

In your code which updates the exported data, make Me.[blue]Recalc[/blue] the last line (don't forget to remove it from the [blue]AfterUpdate[/blue] event!).

Calvin.gif
See Ya! . . . . . .
 
Many thanks TheAceMan. As the update procedure is written as a function in a module I couldn't use the ME keyword. However by referring to the form directly (Forms_StatsSboard.Recalc) in the function this method works fine. Thanks very much for your help

Kind regards
Errol
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top