If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
Limit Combo Box
I will do my best to make some since.
I have a form for entering data into a table named dispatchdetatils The Combo Box named vehiclebox on the form shows vehicle license plates numbers. When a vehicle is chosen a new record is started and the new record milesout field on the dispatchdetails table is populated from the max of the milesin field. Below is what I have in the After update of the combox. What I would like to happen also is if there is a milesin field that is null then do not start the new record but have a pop up appear stating the vehicle is already out. Thank you in advance Private Sub VEHICLEBOX_AfterUpdate() If Not IsNull(Me.VEHICLEBOX) Then Me.milesout = _ DMax("milesin", "dispatchdetails", _ "tagnumber = " & Me.VEHICLEBOX) End If End Sub |
Thread Tools | |
Display Modes | |
|
|