Jump to content
We've recently updated our Privacy Statement, available here ×

cnaranjo

Members
  • Posts

    3
  • Joined

  • Last visited

cnaranjo's Achievements

Newbie

Newbie (1/14)

  • Week One Done
  • One Month Later
  • One Year In
  • First Post Rare
  • Conversation Starter Rare

Recent Badges

0

Reputation

  1. solved :P I must define the parameter not just on the report and on the dataset, there is a parameter section inside the crosstab info where I must define it too.
  2. Hi, I'm doing a report with a crosstab, and the crosstab fields are Hyperlink that send data to a php page, the hyperlink it's ok, if I send the value of the field or the top or left axis of the crosstab that correspond to the field, like this: "./informe6.php?r=rpt_Avance_Semanal_Detalle&f="+$V{fase}+"&t="+$V{TIPO} but I need to send a parameter and when I put it on the link like this: "./informe6.php?r=rpt_Avance_Semanal_Detalle&c="+$P{cliente}+"&f="+$V{fase}+"&t="+$V{TIPO} it sends this error: "Parameter not found: cliente", the parameter is being used by the dataset of the crosstab and the parameter is set in the Parameters Crosstab Data section, I test it with other variables of the dataset that aren't the field value or the top/left axis and it sends the same error, so my question is if the Hyperlink inside a Crosstab can only use the visible variables or is there a way to use other Report Variables/Parameters/Fields?
  3. Hi, I need to show reports on a php site, so I installed php java bridge and it works fine when I create the reports with exportReportToHtmlFile to a directory, the problem is that the php site Im using, works on a way that changes all the path's to files or images, even the ones inside the code of an html, thats why I want to show it direct on the php that compile the report, is there a way todo that? I find a lot of info about generate it on pdf (and I think that can solve my problem) but for this proyect is not an option, it must be on html. Here is my code: $jcm = new JavaClass("net.sf.jasperreports.engine.JasperCompileManager"); $report = $jcm->compileReport($dirJRXML.$informe.".jrxml"); $objClass = new JavaClass("java.lang.Class"); $objClass->forName('com.mysql.jdbc.Driver'); $objDbm = new Java("java.sql.DriverManager"); $objDbConnect = $objDbm->getConnection("jdbc:mysql://localhost:3306/db", "usr", "pass"); $params = new Java("java.util.HashMap"); $jfm = new JavaClass("net.sf.jasperreports.engine.JasperFillManager"); $print = $jfm->fillReport($report,$params,$objDbConnect); $jem = new JavaClass("net.sf.jasperreports.engine.JasperExportManager"); $jem->exportReportToHtmlFile($print,$dirHTML.$informe.".html"); header('Location: html/'.$informe); This create the file on a local folder and then I just redirect to it, like I say its working fine, it create the html file and the report data its fine, but when I redirect to it, the application on wish Im runing this, search for the images (a pixel that jr is puting inside to fill blank spaces) on a path thats not the one JR is placing the image. I cant change the way the application works, so I need to show the report in other way, thats why I want to know if there is a way to not create the file and instead show the report direct on the code or something like that
×
×
  • Create New...