Page 1 of 1
EXECUTE REPORT
Posted: Mon Mar 08, 2010 4:00 pm
by fchirico
...::: SPANISH :::...
Estimado Roberto:
Cómo puedo ejecutar un reporte pero pasándole el nombre del .RMG como una variable?
Lo he intentado así:
cRptaEjecutar := 'pepe'
USE clientes
LOAD REPORT &(cRptaEjecutar)
EXECUTE REPORT &(cRptaEjecutar) PREVIEW SELECTPRINTER
pero me dá error cuando compilo.
...::: ENGLISH :::...
Dear Robert:
How can I run a report but passing it the name. RMG as a variable?
I tried this:
cRptaEjecutar: = 'pepe'
USE clientes
LOAD REPORT & (cRptaEjecutar)
EXECUTE REPORT & (cRptaEjecutar) SELECTPRINTER PREVIEW
but it gives me error when I compile.
Re: EXECUTE REPORT
Posted: Mon Mar 08, 2010 4:33 pm
by Roberto Lopez
fchirico wrote:...::: SPANISH :::...
Estimado Roberto:
Cómo puedo ejecutar un reporte pero pasándole el nombre del .RMG como una variable?
Lo he intentado así:
cRptaEjecutar := 'pepe'
USE clientes
LOAD REPORT &(cRptaEjecutar)
EXECUTE REPORT &(cRptaEjecutar) PREVIEW SELECTPRINTER
pero me dá error cuando compilo.
...::: ENGLISH :::...
Dear Robert:
How can I run a report but passing it the name. RMG as a variable?
I tried this:
cRptaEjecutar: = 'pepe'
USE clientes
LOAD REPORT & (cRptaEjecutar)
EXECUTE REPORT & (cRptaEjecutar) SELECTPRINTER PREVIEW
but it gives me error when I compile.
You can use the ExecuteReport function:
Code: Select all
ExecuteReport ( cReportName , lPreview , lSelect , cOutputFileName )
Re: EXECUTE REPORT
Posted: Mon Mar 08, 2010 5:10 pm
by fchirico
Roberto Lopez wrote:You can use the ExecuteReport function:
Code: Select all
ExecuteReport ( cReportName , lPreview , lSelect , cOutputFileName )
True, sometimes the tree will not let you see the forest.
Thank you!
Re: EXECUTE REPORT
Posted: Mon Mar 08, 2010 5:43 pm
by fchirico
fchirico wrote:Roberto Lopez wrote:You can use the ExecuteReport function:
Code: Select all
ExecuteReport ( cReportName , lPreview , lSelect , cOutputFileName )
True, sometimes the tree will not let you see the forest.
Thank you!
...::: SPANISH :::...
Roberto,
La función ExecuteReport() funcionó perfecto, el problema lo tengo cuando hago el LOAD REPORT.
La idea es ejecutar los RMG desde un menú. En un ListBox tengo los nombres de los RMG cargados y al hacer DobleClick ejecutar ese reporte, por ese motivo necesito cargarlos ( LOAD REPORT ) y luego ejecutarlos ( con el ExecuteReport() que funciona correctamente) .
Entonces... cómo puedo cargar un reporte pasándole el nombre como variable?
Muchas gracias!
...::: ENGLISH :::...
Roberto,
ExecuteReport function () worked perfectly, the problem I have when I do the LOAD REPORT.
The idea is to run the RMG from a menu. In a ListBox I have the names of the RMG loaded and run by double-clicking that report, that is why I need to load (LOAD REPORT) and then run (with ExecuteReport () to work correctly).
Then ... how can I load a report by passing the name as variable?
Thank you very much!
Re: EXECUTE REPORT
Posted: Mon Mar 08, 2010 7:24 pm
by Roberto Lopez
fchirico wrote:fchirico wrote:Roberto Lopez wrote:You can use the ExecuteReport function:
Code: Select all
ExecuteReport ( cReportName , lPreview , lSelect , cOutputFileName )
True, sometimes the tree will not let you see the forest.
Thank you!
...::: SPANISH :::...
Roberto,
La función ExecuteReport() funcionó perfecto, el problema lo tengo cuando hago el LOAD REPORT.
La idea es ejecutar los RMG desde un menú. En un ListBox tengo los nombres de los RMG cargados y al hacer DobleClick ejecutar ese reporte, por ese motivo necesito cargarlos ( LOAD REPORT ) y luego ejecutarlos ( con el ExecuteReport() que funciona correctamente) .
Entonces... cómo puedo cargar un reporte pasándole el nombre como variable?
Muchas gracias!
...::: ENGLISH :::...
Roberto,
ExecuteReport function () worked perfectly, the problem I have when I do the LOAD REPORT.
The idea is to run the RMG from a menu. In a ListBox I have the names of the RMG loaded and run by double-clicking that report, that is why I need to load (LOAD REPORT) and then run (with ExecuteReport () to work correctly).
Then ... how can I load a report by passing the name as variable?
Thank you very much!
LOAD REPORT is translated as an #include, so it is 'solved' at compile time. It can't be loaded at runtime (the same as windows).