Follow this step
Place the dropdown control and draw, make sure that Wizard is not on
1. Right click the comb and rename it tp cboselect.
2. On the row source click on the ... and choose the table you want to retrieve information from.
3. Select the table ID and the name of the field you want.
4. close and choose save when asked to save and continue
5. On the bound column 1
6. Column width 0cm; 4cm
7. Right click on the drop down and click on event
8. Click on After Update and select Event procedure and click ...
past this code seen below
Private Sub cboselect_AfterUpdate()
Dim Title As String
Title = " Sango Plaza Hotel Limited "
On Error GoTo ErrorHandler
Dim StrSearch As String
StrSearch = "[NameID]=" & Me![cboselect]
Me.RecordsetClone.FindFirst StrSearch
Me.Bookmark = Me.RecordsetClone.Bookmark
ErrorHandlerExit:
Exit Sub
ErrorHandler:
MsgBox Err.Description
Resume ErrorHandlerExit
'----------------
Click on the top of the on design mode and select On Current.
Enter this code
On Error GoTo ErrorHandler
Me![cboselect] = Null
ErrorHandlerExit:
Exit Sub
ErrorHandler:
MsgBox "Error No: " & Err.Number & "; Description:" & Err.Description
Resume ErrorHandlerExit
You are done
God luck!
Matthew Ikechukwu
Email:
[email protected]