I am trying to make sure that two objects' values in a form (text box and a combo box) don't already exist in the DB when they make changes to whatever values are already in there hit the cmd btn to do the commit/edit.
Says I have a wrong data type on field varThemeID, which comes from the 1st column from the forms only combo box, column(0).
Field that varThemeID is updating is a Double data type in the table and is declared as such in the code.
normally, varThemeID = 1202842120
I've run the code in a query window and I get the data I need, not sure what else to do, any help would be appreciated.
Says I have a wrong data type on field varThemeID, which comes from the 1st column from the forms only combo box, column(0).
Field that varThemeID is updating is a Double data type in the table and is declared as such in the code.
normally, varThemeID = 1202842120
Code:
Dim varThemeID As Variant
varThemeID = Nz(Me.cbo_ThemeUpdate.Column(0), "0")
If Not IsNull(DLookup("[ServicesID]", "[tbl_Services]", "[ServicesID] = '" & Me.OpenArgs & "'" And "[ThemeID] = '" & varThemeID & "'")) Then
Me.txt_EditConfirm = "Nothing to change or already exists in database"
Me.txt_ServicesNameEdit.SetFocus
Else
I've run the code in a query window and I get the data I need, not sure what else to do, any help would be appreciated.