Skip to Content
0
Former Member
Dec 28, 2011 at 03:01 PM

How to run report using custom driver? Server type USERSPECIFIED fails

29 Views

Hello everyone,

When trying to run report with the crdb_ado custom driver as code shows below, I get an error in Java. It doesn't like the server type USERSPECIFIED enumeration of 1000. What should I use if I want to run the report using custom driver:

IReportLogon crystalReportLogon... 
...
crystalReportLogon.setOriginalDataSource(Boolean.FALSE);
crystalReportLogon.setPromptOnDemandViewing(Boolean.FALSE);
crystalReportLogon.setCustomDatabaseDLLName("crdb_ado.dll");
crystalReportLogon.setCustomServerType(IReportLogon.CeReportServerType.USERSPECIFIED); // Fails here with error below
//[more code that sets credentials,etc]

...

Fails at the line marked above and gives this stack trace. The enumeration for USERSPECIFIED is 1000 but is apparently invalid for the method setCustomServerType

com.crystaldecisions.sdk.exception.SDKException$InvalidArg: The argument has an invalid value 1000

at com.crystaldecisions.sdk.plugin.desktop.report.internal.ReportLogon.setCustomServerType(ReportLogon.java:308)

Edited by: bartimus on Dec 29, 2011 11:08 AM