FoxPro/Visual FoxPro - MOSTRAR RESULTADOS DE UNA CONSULTA EN UNA GRILLA

 
Vista:

MOSTRAR RESULTADOS DE UNA CONSULTA EN UNA GRILLA

Publicado por RICARDO SANCHEZ (2 intervenciones) el 03/07/2007 22:11:02
GRACIAS ME GUSTARIA SABER COMO PUEDO MOSTRAR LOS RESULTADOS DE MI CONSULTA DE LA TABLA CLIENTES EN UNA GRILLA.

EJEMPLO, QUIERO MOSTRAR TODOS LOS DATOS UN CLIENTE SELECCIONANDO SU NOMBRE DESDE UN COMBO. HAGO LA CONSULTA Y COMO LE ESPECIFICO QUE ME MUESTRE LOS RESULTADOS EN LA GRILLA.
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder

RE:MOSTRAR RESULTADOS DE UNA CONSULTA EN UNA GRILL

Publicado por juan fernando (537 intervenciones) el 03/07/2007 22:23:56
supongamos que es el campo nombre
sería algo asi :
Evento clic del Combo1

select tú tabla
Index On nomcliente To clientes
Publ Nom
nom=tabla.Nomcliente
Nom=Thisform.Combo1.Value
abrimos una Texts en el Form para almenar el nombre
que salga del Combo1
Text1
en el evento Gotfocus de la Text este código
Publ nom
Store Space(40)to nom
Thisform.Text1.Value=nom
Thisform.Text1.Refresh

Ahora en el Evento AfterRowColchange del Grid1
Publ Nom
Nom=Thisform.Text1.Value
Set Filter To nomcliente=nom
** aqui no cierres el Filtro con set filter to
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar
sin imagen de perfil

RE:MOSTRAR RESULTADOS DE UNA CONSULTA EN UNA GRILL

Publicado por neo (1604 intervenciones) el 04/07/2007 15:50:52
&& En el Evento Valid() del Combo:

Select Clientes
Set filter to

Set Filter to Upper(Nombre)=upper(alltrim(Thisform.combo1.value))
Thisform.Grid1.Refresh
Go top

&& Evento Lost Focus() del Combo:
Thisform.grid1.column1.text1.Setfocus()


Suerte►
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

RE:MOSTRAR RESULTADOS DE UNA CONSULTA EN UNA GRILL

Publicado por RICARDO SANCHEZ (2 intervenciones) el 05/07/2007 01:52:44
AGRADESCO MUY ESPECIALMENTE A NEO POR TODOS SUS VALIOSOS APORTES, EN VARIAS OPORTUNIDADES NOS HA SACADO DE LIOS TANTO A MI NOVIA JOHANNA COMO A MI. GRACIAS...
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar
sin imagen de perfil

RE:MOSTRAR RESULTADOS DE UNA CONSULTA EN UNA GRILL

Publicado por neo (1604 intervenciones) el 05/07/2007 15:18:09
Me da gusto que los comentarios y apoyo sobre codigo o lo que aporte, sea de utilidad...Gracias por tus comentarios...

Buen Dia!!
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar