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!

Calculating from one form to another

Status
Not open for further replies.

Nickaroo

MIS
Mar 24, 2003
21
US
I have two tables, one the “master name” table and two the overtime table….One to many relationship based on employee num. I am trying to create a data entry form that calculates a dollar amount based on a rate that resides in the master name table and a number field that resides on the data entry from. The “total rate” field is on the same form and is where I want to store this information.

Master.Rate x overtime.number = overtime.total

I do not know how to accomplish this task.

Help

 
Assuming you have a field on your form for Employee Number use the following
Dim rsRate as Variant

rsRate = Dlookup ("[Rate]","Master Name","[Employee Number] = '" & me.Employee_Number & "'")

Me.overtimeTotal = rsRate * me.overtimenumber

HTH



"I know what you're t'inkin', ma petite. Dat Gambit... still de suave one, no?"
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top