fatal error with ireports sc_redir !!!!

Hello ,

First of all , thanks for your good job concerning Ireports intergration !!!
I have installed and try to integrated a reports but I receive a error message write below, what do I wrong ???
I think it’s with sc_redir command but, I cannot find what is wrong !!!

Thanks in advance for your help
Merry Christmas
Can

Fatal error: Call to undefined method grid_XXXXX_apl::nmgp_redireciona_form() in
…wwwroot\scriptcase\app\MyProject\grid_XXXX X\grid_XXXXX.php on line 1938

=====================================
BUTTON CODE

$pdf_query=“SELECT
…”;

$xml_file=“report1.jrxml”;
sc_set_global($pdf_query);
sc_set_global($xml_file);

sc_redir(…/ireports/ireports.php);

=======================================
grid_XXXXX.php CODE

if (isset($this->sc_temp_pdf_query)) {$_SESSION[‘pdf_query’] = $this->sc_temp_pdf_query;}
if (isset($this->sc_temp_xml_file)) {$_SESSION[‘xml_file’] = $this->sc_temp_xml_file;}
if (!isset($this->Campos_Mens_erro) || empty($this->Campos_Mens_erro))
{
//////////////////////////////////////// line 1938 /////////////////////

$this->nmgp_redireciona_form("…/ireports/ireports.php", $this->nm_location, “”,"_self", 440, 630, “ret_self”);

//////////////////////////////////////// //////////////////////////////
};
if (isset($this->sc_temp_pdf_query)) {$_SESSION[‘pdf_query’] = $this->sc_temp_pdf_query;}
if (isset($this->sc_temp_xml_file)) {$_SESSION[‘xml_file’] = $this->sc_temp_xml_file;}

=======================================
APP DIRECTORY TREE and filename

…wwwroot\scriptcase\app\MyProject\ireports

in ireports directory :

\class
ireports.php
report1.jrxml

The error is caused by the file grid_XXXXX_apl.php.
For some reason the function nmgp_redireciona_form() seems not be defined there. Check for it.
As far as I’m concerned it has nothing to do with your report.
Try to redirect to a different form or grid within your project and see if the error persists.

One suggestion regarding your redirection: use the “_blank” parameter (sc_redir(…/ireports/ireports.php,"_blank"):wink: otherwise it could be difficult to return to your application.

jsb

Hello Jsb

There is no grid_XXXXX_apl.php in my grid subdirectory !!!

What can be the reason ?

Thanks in advance
Can

Hi,
I’m sorry I didn’t read your first post carefully enough and didn’t notice that you are talking about a grid. Grids don’t have an apl-file.
You should try to get it running from a single form first.
But again, check if the redirect macro is working properly at all.
I might be wrong, but it seems totally unrelated to the report stuff.

jsb

He did promise strength for the day,
comfort for the tears,
and light for the way.
——————————————————————————
fifa coins or cheap fifa 14 coins