
Buscar en un DataGrid 2 o mas criterios
Publicado por lixander (3 intervenciones) el 26/03/2017 05:53:13
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
Dim buscar As String, criterio As String
If Text3.Text = "" Then
MsgBox ("El Campo se encuentra vacio"), vbInformation
Else
buscar = Text3.Text
If buscar = "" Then Exit Sub
criterio = "Trayecto like '*" & buscar & "*'"
Adodc1.Recordset.MovePrevious
Label7.Caption = CStr(DataGrid1.Appearance)
If Not Adodc1.Recordset.EOF Then
Adodc1.Recordset.Find criterio
End If
If Adodc1.Recordset.EOF Then
Adodc1.Recordset.MoveFirst
Adodc1.Recordset.Find criterio
If Adodc1.Recordset.EOF Then
Adodc1.Recordset.MoveLast
respuesta = MsgBox("La Cedula no esta registrada", vbCritical)
End If
End If
End if
Necisito modicar este codigo para que me busque otro criterio aparte del que se muestra " trayecto " . Visual Basic 6. Espero que me puedan ayudar, Gracias..
Valora esta pregunta


0