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

automated record creation

Status
Not open for further replies.

hjm3857

Vendor
Sep 23, 2002
40
0
0
US
I have a table with a number field. I am looking for an automated process that will take the value entered in this field, run a calculation against the value, and create a new record in another table and insert the calculated value in a field in the new record. I want this to be automated if possible, if not then with vba code that could be intitiated by a user.



 
In the AfterUpdate event of the field the user enters a number in, code like this would be run:

Docmd.SetWarnings False
DoCmd.RunSql "Insert [SecondTable] ([NumberField]) Select " & Me![EnteredNumber] * 50 & " ; "
Docmd.SetWarnings True Anthony J. DeSalvo
President - ScottTech Software
"Integrating Technology with Business"
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top