from a text box you enter the data to search for nombre,identifica,direccion and telefono by means of a button. The button is where I assign the search code, but it does not do the exact search, sometimes it works and other times it does not search according to the entered text.
SELECT clientes2
IF !EMPTY(THISFORM.Text1.Value)
GO TOP
SET ORDER TO
SET ORDER TO nombre
SEEK ALLTRIM(thisform.text1.Value)
GO TOP
SET ORDER TO
SET ORDER TO identifica
SEEK ALLTRIM(thisform.text1.Value)
GO TOP
SET ORDER TO
SET ORDER TO direccion
SEEK ALLTRIM(thisform.text1.Value)
GO TOP
SET ORDER TO
SET ORDER TO telefono
SEEK ALLTRIM(thisform.text1.Value)
thisform.Refresh
ELSE
messagebox('Registro no existe ' + ' ' + THISFORM.Text1.Value)
ENDIF
SELECT clientes2
IF !EMPTY(THISFORM.Text1.Value)
GO TOP
SET ORDER TO
SET ORDER TO nombre
SEEK ALLTRIM(thisform.text1.Value)
GO TOP
SET ORDER TO
SET ORDER TO identifica
SEEK ALLTRIM(thisform.text1.Value)
GO TOP
SET ORDER TO
SET ORDER TO direccion
SEEK ALLTRIM(thisform.text1.Value)
GO TOP
SET ORDER TO
SET ORDER TO telefono
SEEK ALLTRIM(thisform.text1.Value)
thisform.Refresh
ELSE
messagebox('Registro no existe ' + ' ' + THISFORM.Text1.Value)
ENDIF