Hi,
I have very simple requirement.
I would like to create a crystal
report using XML. This
XML file will be decided at run time
(not at design time).
Hence i have added a crystal report viewer control to my windows form and did
not choose any data source (i left it blank currently). Now i am trying to load
XML file with the following simple code.
PropertyBag
crLogOnDetails = new PropertyBag();
crLogOnDetails["Local XML File"] = @"C:\Hosts.xml";
crLogOnDetails["Local Schema File"] = @"C:\Hosts.xsd";
ConnectionInfo conn = new ConnectionInfo();
conn.Attributes = crLogOnDetails;
// create
"Host" table
CrystalDecisions.ReportAppServer.DataDefModel.Table tbl;
tbl = new
CrystalDecisions.ReportAppServer.DataDefModel.Table();
tbl.Name =
"Host";
tbl.ConnectionInfo = conn;
rcDoc.DatabaseController.AddTable(tbl, null);
I am getting exception exactly at the above line (i.e. when adding table to
Database Controller) saying "COMException was unhandled" with error code
0x80004005 Unspecified error.
Can any one please help me regarding how to resolve this.
Thanks in advance,
Kishore