<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Question Re: in CR4E 2, data fields &amp; subreports appear as hyperlinks in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242880#M2290105</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That all depends on the hyperlink - where does it point to?  Does it point back to the originating JSP? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Need to know what's creating the hyperlink first.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it drilldown?  If so, then you can always set CrystalReportViewer.setEnabledDrilldown(false);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sincerely,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ted Ueda&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 07 Oct 2009 13:31:44 GMT</pubDate>
    <dc:creator>ted_ueda</dc:creator>
    <dc:date>2009-10-07T13:31:44Z</dc:date>
    <item>
      <title>in CR4E 2, data fields &amp; subreports appear as hyperlinks</title>
      <link>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaq-p/6242879</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Even though data fields and subreports DO NOT have hyperlinks turned on, they appear in the DHTML report viewer as though they do - i.e. in IE with the "hand" icon - and when a user clicks on it, they get the error shown below.  &lt;STRONG&gt;The question:  How can this feature be turned off?&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;Error 500--Internal Server Error &lt;/P&gt;&lt;P&gt;java.lang.NullPointerException&lt;/P&gt;&lt;P&gt;	at jsp_servlet.__reportviewer._jspService(__reportviewer.java:133)&lt;/P&gt;&lt;P&gt;	at weblogic.servlet.jsp.JspBase.service(JspBase.java:34)&lt;/P&gt;&lt;P&gt;	at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)&lt;/P&gt;&lt;P&gt;	at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)&lt;/P&gt;&lt;P&gt;	at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:283)&lt;/P&gt;&lt;P&gt;	at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:175)&lt;/P&gt;&lt;P&gt;	at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3231)&lt;/P&gt;&lt;P&gt;	at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)&lt;/P&gt;&lt;P&gt;	at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)&lt;/P&gt;&lt;P&gt;	at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2002)&lt;/P&gt;&lt;P&gt;	at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:1908)&lt;/P&gt;&lt;P&gt;	at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1362)&lt;/P&gt;&lt;P&gt;	at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)&lt;/P&gt;&lt;P&gt;	at weblogic.work.ExecuteThread.run(ExecuteThread.java:181)&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 Oct 2009 01:35:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaq-p/6242879</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-10-07T01:35:19Z</dc:date>
    </item>
    <item>
      <title>Re: in CR4E 2, data fields &amp; subreports appear as hyperlinks</title>
      <link>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242880#M2290105</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;That all depends on the hyperlink - where does it point to?  Does it point back to the originating JSP? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Need to know what's creating the hyperlink first.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it drilldown?  If so, then you can always set CrystalReportViewer.setEnabledDrilldown(false);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sincerely,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ted Ueda&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 Oct 2009 13:31:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242880#M2290105</guid>
      <dc:creator>ted_ueda</dc:creator>
      <dc:date>2009-10-07T13:31:44Z</dc:date>
    </item>
    <item>
      <title>Re: in CR4E 2, data fields &amp; subreports appear as hyperlinks</title>
      <link>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242881#M2290106</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Ted, thanks for getting back to me.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You asked &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;That all depends on the hyperlink - where does it point to?  Does it point back to the originating JSP? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Need to know what's creating the hyperlink first.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it drilldown?  If so, then you can always set CrystalReportViewer.setEnabledDrilldown(false);&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There is no hyperlink, but something (report design?  the jsp? I don't know) is treating data fields and subreports as though they are hyperlinks.  Therefore, they are not pointing anywhere.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will try your suggestion regarding setEnabledDrilldown(false).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Bill&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 Oct 2009 14:34:08 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242881#M2290106</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-10-07T14:34:08Z</dc:date>
    </item>
    <item>
      <title>Re: in CR4E 2, data fields &amp; subreports appear as hyperlinks</title>
      <link>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242882#M2290107</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Well, clicking on it leads to the server returning an HTTP 500 error, so there must be a URL request going out when someone clicks on it.  &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You might try Fiddler or Charles HTTP analyzer to determine what URL request is going out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sincerely,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ted Ueda&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 Oct 2009 14:40:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242882#M2290107</guid>
      <dc:creator>ted_ueda</dc:creator>
      <dc:date>2009-10-07T14:40:32Z</dc:date>
    </item>
    <item>
      <title>Re: in CR4E 2, data fields &amp; subreports appear as hyperlinks</title>
      <link>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242883#M2290108</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ted,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;Well, clicking on it leads to the server returning an HTTP 500 error, so there must be a URL request going out when someone clicks on it. &lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;True - an implicit request but not one I set up.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;You might try Fiddler or Charles HTTP analyzer to determine what URL request is going out.&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What would that tell us (what should I look for)?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 Oct 2009 14:54:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242883#M2290108</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-10-07T14:54:05Z</dc:date>
    </item>
    <item>
      <title>Re: in CR4E 2, data fields &amp; subreports appear as hyperlinks</title>
      <link>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242884#M2290109</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You'd use HTTP analyzer to see what request is going to the server, and reference that to the exception being thrown in the _reportviewer.java file, so you'd be able to isolate what's causing the HTTP 500.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sincerely,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ted Ueda&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 Oct 2009 15:11:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242884#M2290109</guid>
      <dc:creator>ted_ueda</dc:creator>
      <dc:date>2009-10-07T15:11:07Z</dc:date>
    </item>
    <item>
      <title>Re: in CR4E 2, data fields &amp; subreports appear as hyperlinks</title>
      <link>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242885#M2290110</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ted,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;jsp code is below... thanks again for all the time you're taking .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;%@page import="com.businessobjects.samples.CRJavaHelper,&lt;/P&gt;&lt;P&gt;com.crystaldecisions.report.web.viewer.CrystalReportViewer,&lt;/P&gt;&lt;P&gt;com.crystaldecisions.sdk.occa.report.application.OpenReportOptions,&lt;/P&gt;&lt;P&gt;com.crystaldecisions.sdk.occa.report.lib.ReportSDKExceptionBase,&lt;/P&gt;&lt;P&gt;com.crystaldecisions.sdk.occa.report.data.*,&lt;/P&gt;&lt;P&gt;java.util.*,&lt;/P&gt;&lt;P&gt;com.crystaldecisions.sdk.occa.report.application.ReportClientDocument"%&amp;gt;&lt;/P&gt;&lt;P&gt;&amp;lt;%!public void jspDestroy() {&lt;/P&gt;&lt;P&gt;		System.out.println("= jspDestroy invoked =");&lt;/P&gt;&lt;P&gt;		//out.println("jspDestroy invoked");&lt;/P&gt;&lt;P&gt;	}%&amp;gt;&amp;lt;%&lt;/P&gt;&lt;P&gt;	//TODO: Add cleanup code to clear out cached report when the jsp is done&lt;/P&gt;&lt;P&gt;	try {&lt;/P&gt;&lt;P&gt;		//******* debugging statements&lt;/P&gt;&lt;P&gt;		System.out.println("====== List of Parameters BEFORE Ass't to variables ==============");&lt;/P&gt;&lt;P&gt;		Enumeration parameterNames = request.getParameterNames();&lt;/P&gt;&lt;P&gt;		while (parameterNames.hasMoreElements()) {&lt;/P&gt;&lt;P&gt;			String parameterName = (String) parameterNames.nextElement();&lt;/P&gt;&lt;P&gt;			String parameterValue = request.getParameter(parameterName);&lt;/P&gt;&lt;P&gt;			System.out.println(parameterName + " = '" + parameterValue + "'");&lt;/P&gt;&lt;P&gt;		}&lt;/P&gt;&lt;P&gt;		System.out.println("====== END of List of Parameters =================================");&lt;/P&gt;&lt;P&gt;		//******* end debugging statements&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;		Object reportSource = null;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;		String reportDesc = null;&lt;/P&gt;&lt;P&gt;		String reportFileName = null;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;		boolean RptHasCustomParam = false; //used to determine whether to invoke generic rpt&lt;/P&gt;&lt;P&gt;		boolean WhereParamIs1EqualsOne = false; //also used to determine whether to invoke generic rpt&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;		if (!"CrystalViewer".equals(request.getParameter("CrystalEventTarget"))) &lt;/P&gt;&lt;P&gt;		    {//******************** Not postback; i.e. initial invocation from Maximo *************************&lt;/P&gt;&lt;P&gt;			System.out.println("====== First pass - pre-postback ==========================");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			//set session attributes&lt;/P&gt;&lt;P&gt;			//** If the Crystal Viewer has to prompt for parameter(s) because they're missing in the array&lt;/P&gt;&lt;P&gt;			//** passed from Maximo, then the parameter reportDesc will be null, so must store the fileDescr&lt;/P&gt;&lt;P&gt;			//** for use in the HTML Title			&lt;/P&gt;&lt;P&gt;			reportDesc = request.getParameter("reportDesc").toString();&lt;/P&gt;&lt;P&gt;			session.setAttribute("reportDesc", reportDesc);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			reportFileName = request.getParameter("reportFile").toString();&lt;/P&gt;&lt;P&gt;			session.setAttribute("reportFileName", reportFileName);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			//added 4/13/09 to enable programmatic updating of db connection string in this jsp&lt;/P&gt;&lt;P&gt;			//commented out 4/15/09; this will now be obtained from the web.xml file&lt;/P&gt;&lt;P&gt;			//dbName = request.getParameter("connectString").toString();&lt;/P&gt;&lt;P&gt;			//session.setAttribute("dbName",dbName);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			if (request.getParameter("where") != null) { //********* debugging *****&lt;/P&gt;&lt;P&gt;				System.out.println("Where parameter detected");&lt;/P&gt;&lt;P&gt;				System.out.println("Where parameter value = '"&lt;/P&gt;&lt;P&gt;						+ request.getParameter("where") + "'");&lt;/P&gt;&lt;P&gt;				System.out.println("Result of .equals 1=1: '"&lt;/P&gt;&lt;P&gt;						+ (request.getParameter("where").equals("1=1"))&lt;/P&gt;&lt;P&gt;						+ "'");&lt;/P&gt;&lt;P&gt;				//********* end debugging *****&lt;/P&gt;&lt;P&gt;				if (request.getParameter("where").equals("1=1")) {&lt;/P&gt;&lt;P&gt;					WhereParamIs1EqualsOne = true; &lt;/P&gt;&lt;P&gt;					//********* debugging *****&lt;/P&gt;&lt;P&gt;					System.out.println("set WhereParamIs1EqualsOne = true");&lt;/P&gt;&lt;P&gt;				}&lt;/P&gt;&lt;P&gt;			}&lt;/P&gt;&lt;P&gt;			System.out.println("====== 'where' test done, ready for client doc setup ==========================");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			//** client doc setup&lt;/P&gt;&lt;P&gt;			//** original code for CR4E1&lt;/P&gt;&lt;P&gt;			ReportClientDocument clientDoc;&lt;/P&gt;&lt;P&gt;			clientDoc = new ReportClientDocument();&lt;/P&gt;&lt;P&gt;			clientDoc.open(reportFileName,OpenReportOptions._openAsReadOnly);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			System.out.println("====== client doc opened ==========================");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			//** log on to db - does it need to be done in common code?&lt;/P&gt;&lt;P&gt;			// ****** BEGIN LOGON TO DATASOURCE ****************  &lt;/P&gt;&lt;P&gt;			{&lt;/P&gt;&lt;P&gt;				System.out.println("======  About to log on to database");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;				//******************************* copied code from 'jrc_change_database_connection.jsp' ***********&lt;/P&gt;&lt;P&gt;				//The DatabaseController will be used to modify the connection properties of the database before &lt;/P&gt;&lt;P&gt;				//viewing the report.  This method iterates through each table in the report and changes the &lt;/P&gt;&lt;P&gt;				//connection info properties.  &lt;/P&gt;&lt;P&gt;				//	Database name, server name, username and password&lt;/P&gt;&lt;P&gt;				// Bill Goss 4/15/09 eliminated hard-coded user &amp;amp; pw, getting it from web.xml file&lt;/P&gt;&lt;P&gt;				String driverName = "oracle.jdbc.driver.OracleDriver";&lt;/P&gt;&lt;P&gt;				String JNDIName = "";&lt;/P&gt;&lt;P&gt;				String user_name = application.getInitParameter("user_name");&lt;/P&gt;&lt;P&gt;				//System.out.println("=== User Name from web.xml = " + user_name);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;				String pw = application.getInitParameter("pw");&lt;/P&gt;&lt;P&gt;				//System.out.println("=== password from web.xml = " + pw);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;				String server_name = application.getInitParameter("server_name");&lt;/P&gt;&lt;P&gt;				//System.out.println("=== server_name from web.xml = " + server_name);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;				String db_name = application.getInitParameter("db_name");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;				System.out.println("=== db_Name from web.xml = " + db_name);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;				String connectString = "jdbc:oracle:thin:@"	+ server_name.toString() &lt;/P&gt;&lt;P&gt;				        				+ ":1521:" + db_name.toString();&lt;/P&gt;&lt;P&gt;				//Switch all tables on the main  and sub-report.  &lt;/P&gt;&lt;P&gt;				CRJavaHelper.changeDataSource(clientDoc, user_name, pw,	connectString, driverName, JNDIName);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;				// logon to database&lt;/P&gt;&lt;P&gt;				//JRCHelperSample.logonDataSource(clientDoc, user_name, pw);&lt;/P&gt;&lt;P&gt;				CRJavaHelper.logonDataSource(clientDoc, user_name, pw);&lt;/P&gt;&lt;P&gt;				System.out.println("Logged on to database");&lt;/P&gt;&lt;P&gt;			}&lt;/P&gt;&lt;P&gt;			// ****** END LOGON TO DATASOURCE **************** 		&lt;/P&gt;&lt;P&gt;			System.out.println("====== DB logon done; ready to connect parms ==========================");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			// connect parameters&lt;/P&gt;&lt;P&gt;			//System.out.println("== inside CONNECT PARAMETERS SNIPPET  ********");&lt;/P&gt;&lt;P&gt;			//DataDefController myDataDefController = clientDoc.getDataDefController();&lt;/P&gt;&lt;P&gt;			//IDataDefinition myDefinition = clientDoc.getDataDefController().getDataDefinition();&lt;/P&gt;&lt;P&gt;			//Fields myFields = clientDoc.getDataDefController().getDataDefinition().getParameterFields().iterator();&lt;/P&gt;&lt;P&gt;			Iterator myIter = clientDoc.getDataDefController().getDataDefinition().getParameterFields().iterator();&lt;/P&gt;&lt;P&gt;			Field myField = null;&lt;/P&gt;&lt;P&gt;			String RptParamName = null;&lt;/P&gt;&lt;P&gt;			String MaximoParamValue = null;&lt;/P&gt;&lt;P&gt;			while (myIter.hasNext()) {&lt;/P&gt;&lt;P&gt;				myField = (Field) myIter.next();&lt;/P&gt;&lt;P&gt;				// DEBUG statement&lt;/P&gt;&lt;P&gt;				RptParamName = myField.getName();&lt;/P&gt;&lt;P&gt;				System.out.println("RptParam: " + RptParamName);&lt;/P&gt;&lt;P&gt;				//Is this parameter in the Maximo list? &lt;/P&gt;&lt;P&gt;				if (request.getParameter(RptParamName) != null) {&lt;/P&gt;&lt;P&gt;					MaximoParamValue = ((String) request.getParameter(RptParamName));&lt;/P&gt;&lt;P&gt;					if (!(RptParamName.equals("where"))) {&lt;/P&gt;&lt;P&gt;						RptHasCustomParam = true;&lt;/P&gt;&lt;P&gt;						System.out.println("--Set RptHasCustomParam");&lt;/P&gt;&lt;P&gt;					}&lt;/P&gt;&lt;P&gt;					System.out.println("-- about to addDiscreteParameterValue");&lt;/P&gt;&lt;P&gt;					//CR4E2 swapped the parameter order... was clientdoc,rptparamname,subrpt name, new value&lt;/P&gt;&lt;P&gt;					//                        new order...     clientdoc,subrpt name, rptparamname, new value&lt;/P&gt;&lt;P&gt;					CRJavaHelper.addDiscreteParameterValue(clientDoc,"",RptParamName, MaximoParamValue);&lt;/P&gt;&lt;P&gt;					System.out.println("--Added Discrete Parameter Value '"&lt;/P&gt;&lt;P&gt;										+ MaximoParamValue&lt;/P&gt;&lt;P&gt;										+ "' from Maximo to report");&lt;/P&gt;&lt;P&gt;				}&lt;/P&gt;&lt;P&gt;			} //end While			&lt;/P&gt;&lt;P&gt;			System.out.println("====== connected parms ==========================");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			if (!RptHasCustomParam &amp;amp;&amp;amp; WhereParamIs1EqualsOne) {&lt;/P&gt;&lt;P&gt;				System.out.println("RptHasCustomParam = '"&lt;/P&gt;&lt;P&gt;						+ RptHasCustomParam&lt;/P&gt;&lt;P&gt;						+ "'; WhereParamIs1EqualsOne = '"&lt;/P&gt;&lt;P&gt;						+ WhereParamIs1EqualsOne + "'");&lt;/P&gt;&lt;P&gt;				// invoke the generic report "Where1Equals1.rpt":&lt;/P&gt;&lt;P&gt;				// set the report file name so if the user navigates in the page viewer it will still use the generic report&lt;/P&gt;&lt;P&gt;				session.setAttribute("reportFileName","Where1Equals1.rpt");&lt;/P&gt;&lt;P&gt;				// - re-instantiate the clientdoc and open it using the generic report name&lt;/P&gt;&lt;P&gt;				clientDoc = new ReportClientDocument();&lt;/P&gt;&lt;P&gt;				clientDoc.open("Where1Equals1.rpt",OpenReportOptions._openAsReadOnly);&lt;/P&gt;&lt;P&gt;				// -	add ReportName as discrete parameter with value from reportDesc &lt;/P&gt;&lt;P&gt;				//JRCHelperSample.addDiscreteParameterValue(clientDoc, "ReportName", "",(String) request.getParameter("reportDesc"));&lt;/P&gt;&lt;P&gt;				System.out.println("reportDesc for 1=1 rpt = '"	+ reportDesc + "'");&lt;/P&gt;&lt;P&gt;				CRJavaHelper.addDiscreteParameterValue(clientDoc,"", "ReportName",  reportDesc);&lt;/P&gt;&lt;P&gt;			} else {&lt;/P&gt;&lt;P&gt;				//	&amp;gt;&amp;gt; use the existing clientdoc to supply the report source			&lt;/P&gt;&lt;P&gt;			}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			//** reportsource&lt;/P&gt;&lt;P&gt;			reportSource = clientDoc.getReportSource();&lt;/P&gt;&lt;P&gt;			session.setAttribute("ReportSource", reportSource);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			//** clean up&lt;/P&gt;&lt;P&gt;			clientDoc.close();&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			System.out.println("====== end of init logic (non-postback) ==========================");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;		} else {//******************* postback *****************************************************************************&lt;/P&gt;&lt;P&gt;			System.out.println("====== processing postback ==========================");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			reportDesc = session.getAttribute("reportDesc").toString();&lt;/P&gt;&lt;P&gt;			System.out.println("== got reportDesc: " + reportDesc.toString());&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			reportFileName = session.getAttribute("reportFileName").toString();&lt;/P&gt;&lt;P&gt;			System.out.println("== got reportFileName: " + reportFileName.toString());&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			reportSource = session.getAttribute("ReportSource");&lt;/P&gt;&lt;P&gt;			System.out.println("== got reportSource: " 	+ reportSource.toString());&lt;/P&gt;&lt;P&gt;		}&lt;/P&gt;&lt;P&gt;		;&lt;/P&gt;&lt;P&gt;		//********************************* end init vs. postback logic **************************************&lt;/P&gt;&lt;P&gt;		//********************************* begin common code           **************************************&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;		//** debug&lt;/P&gt;&lt;P&gt;		System.out.println("reportFileName = '" + reportFileName + "'");&lt;/P&gt;&lt;P&gt;		//** end debug&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;		//* Set the page title to the report description from Maximo&lt;/P&gt;&lt;P&gt;		out.println("&amp;lt;TITLE&amp;gt;" + reportDesc + " Maximo Report&amp;lt;/TITLE&amp;gt;");&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;		{&lt;/P&gt;&lt;P&gt;			System.out.println("====== Create &amp;amp; set properties for CR Viewer ================");&lt;/P&gt;&lt;P&gt;			// &amp;gt;&amp;gt; Create the CrystalReportViewer object&lt;/P&gt;&lt;P&gt;			CrystalReportViewer crystalReportPageViewer = new CrystalReportViewer();&lt;/P&gt;&lt;P&gt;			crystalReportPageViewer.setReportSource(reportSource);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			// set viewer attributes; this is where PDF vs. ActiveX would be set as well&lt;/P&gt;&lt;P&gt;			crystalReportPageViewer.setOwnPage(true);&lt;/P&gt;&lt;P&gt;			crystalReportPageViewer.setOwnForm(true);&lt;/P&gt;&lt;P&gt;			// trying to clear saved/cached data; this allows the user to force a refresh of the data (Crystal will re-prompt for&lt;/P&gt;&lt;P&gt;			// parameters&lt;/P&gt;&lt;P&gt;			//crystalReportPageViewer.refresh(); //if this is invoked, the report throws away the parameter values that were passed from Maximo&lt;/P&gt;&lt;P&gt;			crystalReportPageViewer.setHasRefreshButton(true);&lt;/P&gt;&lt;P&gt;			crystalReportPageViewer.setEnableParameterPrompt(true);&lt;/P&gt;&lt;P&gt;			//crystalReportPageViewer.setReuseParameterValuesOnRefresh(true);&lt;/P&gt;&lt;P&gt;			crystalReportPageViewer.setHasLogo(false);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			// Apply the viewer preference attributes&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;			System.out.println("====== invoke PageViewer.processHttpRequest ==================");&lt;/P&gt;&lt;P&gt;			// Process the report&lt;/P&gt;&lt;P&gt;			crystalReportPageViewer.processHttpRequest(request,&lt;/P&gt;&lt;P&gt;					response, application, null);&lt;/P&gt;&lt;P&gt;			System.out.println("====== processed HttpRequest using pageviewer ================");&lt;/P&gt;&lt;P&gt;		}&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;	} catch (ReportSDKExceptionBase e) {&lt;/P&gt;&lt;P&gt;		out.println(e);&lt;/P&gt;&lt;P&gt;	}&lt;/P&gt;&lt;P&gt;%&amp;gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 Oct 2009 15:14:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/in-cr4e-2-data-fields-subreports-appear-as-hyperlinks/qaa-p/6242885#M2290110</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-10-07T15:14:00Z</dc:date>
    </item>
  </channel>
</rss>

