ChadMarsh
asked on
Crystal connection issues with a dataset provided by a dll
Hello,
I'm consuming a web service with in a dll that has a public function that returns a dataset.
I'm trying to connect to it with Crystal Crystal reports. I'm pretty sure the "Double Hop" rule while passing my credentials is causing me grief even though I'm supplying a NetworkCredential. If I reference the dll in a test project it brings back the data, but when I try to connect to it with Crystal I get "logon failed Details:mscorlib : Exception has been thrown by the target of an invocation.
Any ideas on how to get a around this would be appreciated.
Here is my class from within the dll:
public class cEntry
{
private EntryWrapper.entry.Service 1 t = new EntryWrapper.entry.Service 1();
DataSet relational_data;
public DataSet tickets()
{
string u = ConfigurationManager.AppSe ttings["us er"];
string p = ConfigurationManager.AppSe ttings["pa ss"];
string d = ConfigurationManager.AppSe ttings["do main"];
t.Credentials = new System.Net.NetworkCredenti al(u, p, d);//Send credentials
string strWeb = t.ReportTest("F241A905-89B 1-416d-8DC 2-8C2EA1A6 B434", ""); //Get xml string from Entry
XmlDocument doc = new XmlDocument();
string inputXml = strWeb;
doc.LoadXml(inputXml);
XslCompiledTransform xslTransform = new XslCompiledTransform(false );
xslTransform.Load(XmlReade r.Create(n ew StringReader(Resource.tick et))); //Load xlst string to the transform object
StringBuilder result = new StringBuilder();
XmlWriter output = XmlWriter.Create(result);
xslTransform.Transform(doc , output); //Apply xlst to the xml file
XmlTextReader xml_reader = new XmlTextReader(new StringReader(result.ToStri ng())); //read the file and convet to xml
relational_data = new DataSet();
relational_data.ReadXml(xm l_reader);
return relational_data;
}
I'm consuming a web service with in a dll that has a public function that returns a dataset.
I'm trying to connect to it with Crystal Crystal reports. I'm pretty sure the "Double Hop" rule while passing my credentials is causing me grief even though I'm supplying a NetworkCredential. If I reference the dll in a test project it brings back the data, but when I try to connect to it with Crystal I get "logon failed Details:mscorlib : Exception has been thrown by the target of an invocation.
Any ideas on how to get a around this would be appreciated.
Here is my class from within the dll:
public class cEntry
{
private EntryWrapper.entry.Service
DataSet relational_data;
public DataSet tickets()
{
string u = ConfigurationManager.AppSe
string p = ConfigurationManager.AppSe
string d = ConfigurationManager.AppSe
t.Credentials = new System.Net.NetworkCredenti
string strWeb = t.ReportTest("F241A905-89B
XmlDocument doc = new XmlDocument();
string inputXml = strWeb;
doc.LoadXml(inputXml);
XslCompiledTransform xslTransform = new XslCompiledTransform(false
xslTransform.Load(XmlReade
StringBuilder result = new StringBuilder();
XmlWriter output = XmlWriter.Create(result);
xslTransform.Transform(doc
XmlTextReader xml_reader = new XmlTextReader(new StringReader(result.ToStri
relational_data = new DataSet();
relational_data.ReadXml(xm
return relational_data;
}
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Well, I ended up writing a script component in an SSIS. I'm just going to put the data into SQL and report off of that. Thanks for the reply though
ASKER
Crystal is on the same server. Actually that server has the Business View Manager, Crystal Report Server and Crystal Developer. They run on a separate drive though. I has Crystal on the phone yesterday and they seemed to be scratching their head over it. The data that I'm pulling is from a proprietary database that Team Headquarters Entry uses. It's all XML based so the web service was the easiest way to get the data. I went one step further and bypassed the webservice and queried the data directly from the dll. Same error, unfortunately. I re-opened my ticket with Crystal.
The other strange thing that the Crystal support rep had be do was connect to my local copy of the dll and create a report. That worked. Then switch the datasource to the network copy of the dll. That worked. The only problem is when you save the report and exit, you get the error when you try to open it again.
Chad