Private Sub DodajUslov(Vrijednost, ImePolja As String, Kriterija As String, Brojac As Integer) If Trim(Format$(Vrijednost)) = "" Then GoTo Kraj If IsNumeric(Vrijednost) = False Then Vrijednost = Chr(39) & Vrijednost & Chr(42) & Chr(39) End If If IsDate(Vrijednost) Then Vrijednost = "#" & Vrijednost & "#" End If If Brojac > 0 Then Kriterija = Kriterija & " and " End If Kriterija = (Kriterija & ImePolja & " Like " & Vrijednost) Brojac = Brojac + 1 Kraj: End Sub