Hi, since i have added a few lines of code to my database from the VBE, i have the window:
"Microsoft Office Access has encountered a problem and needs to close. We are sorry for the inconvenience"
when i open the database. The code lines are:
These lines have to be added because in 2007 version of Access, the form applies rarely a random (?) filter when no filter is applied from the combobox for doing it (when this happens, whereCondition -String type variable- is built with the identity number of the records shown separated with a comma, so that variable stops being a null variable and a 0 lenght string).
Does anybody know what is wrong in this implementation or in the DB?
Thanks in advance for any help.
"Microsoft Office Access has encountered a problem and needs to close. We are sorry for the inconvenience"
when i open the database. The code lines are:
Code:
Private Sub Form_Open(Cancel As Integer)
If IsNull(whereCondition) = False Then
If whereCondition = "" Then
Me.FilterOn = False
End If
Else
Me.FilterOn = False
End If
End Sub
These lines have to be added because in 2007 version of Access, the form applies rarely a random (?) filter when no filter is applied from the combobox for doing it (when this happens, whereCondition -String type variable- is built with the identity number of the records shown separated with a comma, so that variable stops being a null variable and a 0 lenght string).
Does anybody know what is wrong in this implementation or in the DB?
Thanks in advance for any help.