consulto por una "pequeña dudita", se trata de informacion de un campo que no he podido imprimir no se que mas hacerle para que salga, he pensado que debo pasar la informacion de la consulta a una variable y luego mandarla a imprimir pero el lio es que no he entendido donde se guarda el dato cuando hago la consulta, ya me volvio a surgir la misma inquietud al tratar que otro dato consultado aparesca en un label.
alguien podria ser tan amable de ayudarme a entender esto?
ustedes han sido muy colaboradores conmigo y se los agradezco mucho!!!
Cita:
Set wrkODBC = CreateWorkspace("", "admin", "", dbUseODBC)
Set conEdits = wrkODBC.OpenConnection("grado", , , _
"ODBC;DATABASE=deposito;DSN=grado;OPTION=0;PORT=0; SERVER=localhost;UID=root")
Set qdfTemp = conEdits.CreateQueryDef("SELECT NOM_USUARIO, NOM_MANUAL From USUARIOS, MANUAL Where COD_USUARIO = " & Text1.Text & " AND COD_MANUAL = '" & Text3.Text & "'")
With qdfTemp
.Prepare = dbQUnprepare
.SQL = "SELECT NOM_USUARIO, NOM_MANUAL From USUARIOS, MANUAL Where COD_USUARIO = " & Text1.Text & " AND COD_MANUAL = '" & Text3.Text & "'"
.Execute
Printer.CurrentX = 0: Printer.CurrentY = 550: Printer.Print "Usuario"
Printer.CurrentX = 560: Printer.CurrentY = 550: Printer.Print ":"
Printer.CurrentX = 610: Printer.CurrentY = 550: Printer.Print NOM_USUARIO
Printer.CurrentX = 0: Printer.CurrentY = 750: Printer.Print "Manual"
Printer.CurrentX = 560: Printer.CurrentY = 750: Printer.Print ":"
Printer.CurrentX = 610: Printer.CurrentY = 750: Printer.Print NOM_MANUAL
Printer.EndDoc
End With
conEdits.Close
wrkODBC.Close
Set conEdits = wrkODBC.OpenConnection("grado", , , _
"ODBC;DATABASE=deposito;DSN=grado;OPTION=0;PORT=0; SERVER=localhost;UID=root")
Set qdfTemp = conEdits.CreateQueryDef("SELECT NOM_USUARIO, NOM_MANUAL From USUARIOS, MANUAL Where COD_USUARIO = " & Text1.Text & " AND COD_MANUAL = '" & Text3.Text & "'")
With qdfTemp
.Prepare = dbQUnprepare
.SQL = "SELECT NOM_USUARIO, NOM_MANUAL From USUARIOS, MANUAL Where COD_USUARIO = " & Text1.Text & " AND COD_MANUAL = '" & Text3.Text & "'"
.Execute
Printer.CurrentX = 0: Printer.CurrentY = 550: Printer.Print "Usuario"
Printer.CurrentX = 560: Printer.CurrentY = 550: Printer.Print ":"
Printer.CurrentX = 610: Printer.CurrentY = 550: Printer.Print NOM_USUARIO
Printer.CurrentX = 0: Printer.CurrentY = 750: Printer.Print "Manual"
Printer.CurrentX = 560: Printer.CurrentY = 750: Printer.Print ":"
Printer.CurrentX = 610: Printer.CurrentY = 750: Printer.Print NOM_MANUAL
Printer.EndDoc
End With
conEdits.Close
wrkODBC.Close