Hello, Juan,
SetXailerDataSet( FrPrn,"oMemDataSet1", ::oMemDataSet1 )
FrPrn:LoadFromFile(Application:oMainform:RepDir+"2.fr3")
BUT NOT:
FrPrn:LoadFromFile(Application:oMainform:RepDir+"2.fr3")
SetXailerDataSet( FrPrn,"oMemDataSet1", ::oMemDataSet1 )
It is axiom in FRH: Data must be defined BEFORE report loading. Report
binding data during its loading.
Sorry for English.
---
Spirin Sergey.
"Paritet Soft" Company.
FRH sales:
http://www.paritetsoft.ru/frh.htm
FRAX sales:
http://www.paritetsoft.ru/frax.htm
> Imposible Miguel he intentado crear un ejemplo partiendo del codigo
> descargado,pero me tira el error al
> ejecutatar el reporte de que el dataset no existe.
>
> lo que se me resiste es a saber donde colocar el dataset(nombre) en el
> reporte con el visual fast report
>
> Gracia
>
> FrPrn := frReportManager():new()
> FrPrn:SetTitle( "Listado" )
>
> Application:oMainform:RepDir := CurDrive() +":"+ CurDir() + 'REPS'
> Application:oMainform:ResDir := CurDrive() +":"+ CurDir() +
> 'LANGRES'
>
> FrPrn:LoadLangRes(Application:oMainform:ResDir + "spanish.xml")
> FrPrn:LoadFromFile(Application:oMainform:RepDir+"2.fr3")
>
> SetXailerDataSet( FrPrn,"oMemDataSet1", ::oMemDataSet1 )
>
> FrPrn:ShowReport()
> FrPrn:DestroyFR()
>
> RETURN Nil
>
> //---------------------------------------------------------- -----------------------------------------------------------
> Function SetXailerDataSet(oFrManager,
> cFrAlias,oDataSet,lRelation,bRelation)
> //---------------------------------------------------------- -----------------------------------------------------------
> local cStr:='', x
>
> IF lRelation==NIL
> bRelation:={||nil}
> Endif
>
> for x := 1 to oDataSet:FieldCount()
> cStr+=oDataSet:FieldName(x) + ";"
> next
>
> oFrManager:SetUserDataSet(cFrAlias, cStr,;
> {||oDataSet:GoTop(),Eval(bRelation)},;
> {||oDataSet:Skip(1),Eval(bRelation)}, ;
> {||oDataSet:Skip(1),Eval(bRelation)}, ;
> {||oDataSet:Eof()},;
>
> {|cField|oDataSet:oFieldByName(cField):FieldGet()})
>
> Return Nil
> "Miguel A. Torrellas" <
miguel@torrellas.net> escribió en el mensaje
> news:[email=4ae01af0@svctag-j7w3v3j....]4ae01af0@svctag-j7w3v3j....[/email]
>> Descarga esta demo; te servirá de gran ayuda.
>>
>>
http://www.ciber-tec.d2g.com/objeto/fastreports.rar
>>
>> Saludos. Miguel A. Torrellas
>>
>> "Miguel A. Torrellas" <
miguel@torrellas.net> escribió en el mensaje de
>> noticias:4adf6902$[email=1@svctag-j7w3v3j....]1@svctag-j7w3v3j....[/email]
>>> Hola,
>>>
>>> Mira este proyecto
>>>
http://www.paritetsoft.ru/downloads/frh_demo_xailer.zip
>>>
>>> Busca la función
>>>
>>> function SetXailerDataSet(oFrManager, cFrAlias, oDataSet)
>>> //---------------------------------------------------------- --------------------
>>> local cStr:='', x
>>>
>>> for x := 1 to oDataSet:FieldCount()
>>> cStr+=oDataSet:FieldName(x) + ";"
>>> next
>>>
>>> oFrManager:SetUserDataSet(cFrAlias, cStr,;
>>> {||oDataSet:GoTop()}, {||oDataSet:Skip(1)},
>>> ;
>>> {||oDataSet:Skip(-1)}, {||oDataSet:Eof()},;
>>>
>>> {|cField|oDataSet:oFieldByName(cField):FieldGet()})
>>>
>>> Return Nil
>>>
>>> Saludos. Miguel A. Torrellas
>>>
>>> "Juan Jose" <
correo@jjlopezg.jazztel.es> escribió en el mensaje de
>>> noticias:4adf31cd$[email=1@svctag-j7w3v3j....]1@svctag-j7w3v3j....[/email]
>>>> Hola
>>>>
>>>> Alguien sabe como pasar un oMemDataSet a Fast Report, agradeceria
>>>> algun ejemplo.
>>>>
>>>> Gracias
>>>>
>>>>
>>>> __________ Información de ESET NOD32 Antivirus, versión de la base de
>>>> firmas de virus 4529 (20091021) __________
>>>>
>>>> ESET NOD32 Antivirus ha comprobado este mensaje.
>>>>
>>>>
http://www.eset.com
>>>>
>>>>
>>>>
>>>>
>>
>> __________ Información de ESET NOD32 Antivirus, versión de la base de
>> firmas de virus 4531 (20091022) __________
>>
>> ESET NOD32 Antivirus ha comprobado este mensaje.
>>
>>
http://www.eset.com
>>
>>
>>
>
>
>
> __________ Información de ESET NOD32 Antivirus, versión de la base de
> firmas de virus 4533 (20091022) __________
>
> ESET NOD32 Antivirus ha comprobado este mensaje.
>
>
http://www.eset.com
>
>
>
>