c# - How to bind crystal report with linq to entities Method -
i facing error while binding crystal report class library's method using linq entities.please me .error is:dataset not support system.nullable<>.following code.
reportdocument customerreport = new reportdocument(); customerreport.load(server.mappath("sample.rpt")); ilist<customer> cs; cs = databasebase.getallcustomers(); customerreport.setdatasource(cs); crystalreportviewer2.reportsource = customerreport; crystalreportviewer2.databind();
dscustomer dscs = new dscustomer(); string conn = system.configuration.configurationmanager.connectionstrings["crmconnectionstring"].connectionstring; string statement = "select * customer"; sqldataadapter dastatement = new sqldataadapter(statement, conn); dastatement.fill(dscs._dscustomer); reportdocument rpt = new reportdocument(); rpt.load(server.mappath("viewcustomer.rpt")); rpt.setdatasource(dscs); this.crystalreportviewer1.reportsource = rpt;
Comments
Post a Comment