Ok! a ver si este te sirve!
'Si ya hay un filtro agregas el AND
If Len(ContentSQL) > 0 Then ContentSQL = ContentSQL & " AND "
Código VB:
Ver originalContentSQL = ""
If Len(Text1.Text) > 0 Then
'Aplicamos filtro
ContentSQL = ContentSQL & " codcat='" & Text1 & "'"
End If
If Len(Text2.Text) >0 Then
'Si ya hay un filtro agregas el AND
If Len(ContentSQL) > 0 Then ContentSQL = ContentSQL & " AND "
'Aplicamos filtro
ContentSQL = ContentSQL & " codmarca='" & Text2 & "'"
End If
If Not rsProd.EOF Then
rsProd.Filter = ContentSQL
End If