Any help will appreciated.
Table tblAll
Country
City
Cost
Cost2
Inside Form have pull down.
cboCountry
cboCity
Then automate Cost into field
txtItemDesc
and Cost2 into Field
txtItemDesc
Code:
Private Sub cboCity_AfterUpdate()
Me.txtItemDesc = DLookup("[Cost]", "tblAll", "[City] ='" & _
[Forms]![frmlAdditions]![cboCity] & "'")
Me.txtItemDesc2 = DLookup("[Cost2]", "tblAll", "[City] ='" & _
[Forms]![frmlAdditions]![cboCity] & "'")
End Sub
Problem is that in my tblAll I have repeating items in Country and City with in the fields therefore with cboCity code. It only will produce the cost for the first time in the City field.
What I need is for this on cboCity after update if Country and City than cost.
Hope I have list enought to make sense.
_________________
Neither are working. I need this done by tonight for a project. So any help please. Last thing.
Table tblAll
Country
City
Cost
Cost2
Inside Form have pull down.
cboCountry
cboCity
Then automate Cost into field
txtItemDesc
and Cost2 into Field
txtItemDesc
Code:
Private Sub cboCity_AfterUpdate()
Me.txtItemDesc = DLookup("[Cost]", "tblAll", "[City] ='" & _
[Forms]![frmlAdditions]![cboCity] & "'")
Me.txtItemDesc2 = DLookup("[Cost2]", "tblAll", "[City] ='" & _
[Forms]![frmlAdditions]![cboCity] & "'")
End Sub
Problem is that in my tblAll I have repeating items in Country and City with in the fields therefore with cboCity code. It only will produce the cost for the first time in the City field.
What I need is for this on cboCity after update if Country and City than cost.
Hope I have list enought to make sense.
_________________
Neither are working. I need this done by tonight for a project. So any help please. Last thing.