Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: crystal report running from java application Post Reply Post New Topic
Author Message
malli
Newbie
Newbie


Joined: 13 Apr 2009
Location: India
Online Status: Offline
Posts: 3
Quote malli Replybullet Topic: crystal report running from java application
    Posted: 11 May 2009 at 10:04pm
Hi,

I am working on crystal reports x1. I created one rpt file which will take one parameter to filter the output from database.
from one jsp page I am passing the value to that report parameter.
I am setting the parameter to the report like below.


                Fields oFields = new Fields();  
                ParameterField portfolio = new ParameterField();
                portfolio.setName("ScreenName");
               
           
                Values oValues = new Values();
                ParameterFieldDiscreteValue oParameterFieldDiscreteValue = new ParameterFieldDiscreteValue();
              
               
                oParameterFieldDiscreteValue.setValue("admin");
                oValues.add(oParameterFieldDiscreteValue);
                portfolio.setCurrentValues(oValues);
                portfolio.setReportName(fileName);

and this is the code to the report viewer.

viewer = new CrystalReportViewer();
                ConnectionInfos connectionInfos =new ConnectionInfos();
                connectionInfos.add(connectionInfo);
                viewer.setDatabaseLogonInfos(connectionInfos);
                 viewer.setName("admin");
                viewer.setOwnPage(false);
                viewer.setParameterFields(oFields);

it is working fine , but here is one problem, that i was setting the report parameter but report engine not taking that value, it itself producing one output jsp page which will accept the report parameter , after that it is generating the report. Here I dont want that page produced by the  reporting engine. please help me how to avoid that page.

regards,
Malli.


Edited by malli - 17 May 2009 at 10:54pm
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.016 seconds.