I am new to RDLC reporting, my requirement is simple. I have prepared a report and I have used some parameters in that report Dynamic data is set to populate.
Now I need to display the table dynamically, so what did I do:
Dataset Invoice Somuri D = new dataset (); Datatyal table = new datatelle (); Table.TableName = "summary"; Table Columns Add ("name", typef (string)); Table.Rows.Add (Invoice TotalBooking); Table. road. Add ("pound" + invoice; bill amount); Table. road. Add ("£" + invoice. Bill Amount + "
" + "£" + Invoice. VAT Aman); Table. road. Add ("pound" + invoice .Net amounts); InvoiceSummaryDs.Tables.Add (table); ReportDataSource rptDataSource = New ReportDataSource ("DSPrice", InvoiceSummaryD Tables [0]); Rv.LocalReport.DataSources.Add (rptDataSource); Rv.LocalReport.SetParameters (parms); Rv.LocalReport.Refresh ();
So there is no problem with the server side code but I get an error in the report: Error 13 Dataset refers to the 'DS_NAME' data source, which does not exist.
Error 14 tabilics is in the 'Tablix1' report, but the report does not have dataset. Datasets are not allowed in reports without datasets.
In the rdlc file I created a dataset with the same name "DSPrice" is not a source because I do not want to dynamically move data from server side here.
I have already seen this example:
Dynamic RDLC generated - Table
contains Dynamic Table binding is likely to create dynamic reports, but I do not want to create dynamic reports.
Nobody guides me that what is the solution? Any help would be appreciated.
Finally, I resolved this issue automatically.
A brief summary of my requirements: I wanted to pair the dataset with code in my RDLC report table.
When I created the table inside the RDLC report, then why did I get the table given to provide the data source for the above error and why I got confused? I need to set it with C # coding.
Then I came to know that the RDLC report does not know if you are going to provide a data source with code until you create a dynamic report via coding and I do not want to be dynamic Report.
Solution:
1) Create a place holder dataset with the same name that you want to pass by code 2) the same column in that dataset And name 3) Assign that dataset to table data source inside your report 4) and use the same name to pass from coding 5) This way you will not get that error and you can easily get the dynamic dataset Can pass.
Comments
Post a Comment