Espero me puedan ayudar!!
Publicado por Efren (185 intervenciones) el 16/01/2004 20:16:46
Hola foro ojala me puedan ayudar a salir de este atoradero: Tengo lo siguiente
Private Sub idea3_Click()
Dim sql_idea As String
Dim etiqueta1 As String
Dim etiqueta2 As String
Dim preg As String
Dim sqlideas As DataEnvironment1
Set sqlideas = DataEnvironment1
preg = "idea3"
etiqueta1 = "Ideas de la Pregunta 3:"
etiqueta2 = "Ideas para los medios de comunicación"
sql_idea = "Select idea3 from TPreguntas where LEN(idea3)> 0"
sqlideas.Commands("ideas").CommandText = sql_idea
sqlideas.Commands("ideas").Execute
DataReport1.Sections("Sección1").Controls("txtidea").DataField = preg
DataReport1.Sections("Section2").Controls("Etiqueta1").Caption = Trim(etiqueta1)
DataReport1.Sections("Section2").Controls("Etiqueta2").Caption = Trim(etiqueta2)
DataReport1.Show
Set sqlideas = Nothing
End Sub
Cuando lo hago por primera vez todo sale bien, el problema es cuando mando llamar a otro reporte de otra idea. osea UNOO IGUAL QUE EL ANTERIOR PERO CON OTRA IDEA..
El error es este: DataField 'ideas.idea4' not found..
LO QUE QUIERO ES METER TODOS LOS DATOS DE UN CAMPO LLAMADO ideaX EN UN REPORTE, PERO SON VARIOS CAMPOS SON COMO 20, Y SOLO UTILIZO UN DATAREPORT, COMO LO PUEDO HACER???
Private Sub idea3_Click()
Dim sql_idea As String
Dim etiqueta1 As String
Dim etiqueta2 As String
Dim preg As String
Dim sqlideas As DataEnvironment1
Set sqlideas = DataEnvironment1
preg = "idea3"
etiqueta1 = "Ideas de la Pregunta 3:"
etiqueta2 = "Ideas para los medios de comunicación"
sql_idea = "Select idea3 from TPreguntas where LEN(idea3)> 0"
sqlideas.Commands("ideas").CommandText = sql_idea
sqlideas.Commands("ideas").Execute
DataReport1.Sections("Sección1").Controls("txtidea").DataField = preg
DataReport1.Sections("Section2").Controls("Etiqueta1").Caption = Trim(etiqueta1)
DataReport1.Sections("Section2").Controls("Etiqueta2").Caption = Trim(etiqueta2)
DataReport1.Show
Set sqlideas = Nothing
End Sub
Cuando lo hago por primera vez todo sale bien, el problema es cuando mando llamar a otro reporte de otra idea. osea UNOO IGUAL QUE EL ANTERIOR PERO CON OTRA IDEA..
El error es este: DataField 'ideas.idea4' not found..
LO QUE QUIERO ES METER TODOS LOS DATOS DE UN CAMPO LLAMADO ideaX EN UN REPORTE, PERO SON VARIOS CAMPOS SON COMO 20, Y SOLO UTILIZO UN DATAREPORT, COMO LO PUEDO HACER???
Valora esta pregunta


0