Hi
I can not find what i am doing wrong with this code.
Access does not give me any error message... it just does not show the correct data that i expect.
I use this code to filter in a listbox.
the problem is with the row in bold. It is something there that is not correct and i cant figure out what and why...
ProfileArchived is Null does not trigger... it still shows cells that do have data in them.
I can not find what i am doing wrong with this code.
Access does not give me any error message... it just does not show the correct data that i expect.
I use this code to filter in a listbox.
the problem is with the row in bold. It is something there that is not correct and i cant figure out what and why...
Code:
strSource = "SELECT Profile_Table.Profile_ID, Profile_Table.FirstName, Profile_Table.LastName, Profile_Table.Personnummer, Profile_Table.AnstalldSom, Profile_Table.JobbarPa, Profile_Table.WorkEndDate, Profile_Table.JobbProcent " & _
"FROM Profile_Table " & _
"Where (Profile_Table.Profile_ID Like '*" & Me.txtSearch.Text & "*' " _
& "or FirstName Like '*" & Me.txtSearch.Text & "*' " _
& "or LastName Like '*" & Me.txtSearch.Text & "*' " _
& "or Personnummer Like '*" & Me.txtSearch.Text & "*' " _
& "or Anstalldsom Like '*" & Me.txtSearch.Text & "*' " _
& "or JobbProcent Like '*" & Me.txtSearch.Text & "*' " _
& "or Anstallningsform Like '*" & Me.txtSearch.Text & "*' " _
[B] & "or JobbarPa Like '*" & Me.txtSearch.Text & "*') AND ProfileArchived Is Null AND Anstallningsform = 'Tillsvidare (fast)' OR Anstallningsform = 'Visstid (tidsbegränsad)' "[/B]
Me.ListPicker.RowSource = strSource
Me.ListPicker.Requery