Click here to Skip to main content
15,867,594 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello House,

I have been working on a C# Winform project that most parts have to do with report, i am

using ms report(rdlc), i have been able to display the report on my system, but while

deploying to another system, it's not displaying the report, the error i am having is:

the source contains no datarows below is my code:

C#
DataSet1TableAdapters.SelectRegisteredParentTableAdapter tb1 = new DataSet1TableAdapters.SelectRegisteredParentTableAdapter( );
                DataSet1.SelectRegisteredParentDataTable ds = tb1.GetData( );
                Microsoft.Reporting.WinForms.ReportDataSource reportDataSource1 = new Microsoft.Reporting.WinForms.ReportDataSource( "DataSet1", ds.AsEnumerable( ).CopyToDataTable( ) );
                reportViewer1.LocalReport.DataSources.Clear( );
                reportViewer1.LocalReport.ReportPath = "Report1.rdlc";
                reportViewer1.LocalReport.DataSources.Add( reportDataSource1 );
                reportViewer1.RefreshReport( )


Please does anyone know how to fix this? Thanks in advance.
Posted
Comments
DamithSL 28-May-14 7:18am    
what you mean by another system? how you know that the error is coming from this code block?
Uwakpeter 28-May-14 7:41am    
that is deploying the application to another computer it doesn't show the report, i am not sure where the error is coming from, i pasted the code so that others who may want to see the code i am using can have a look at it. The report works fine on my computer.
[no name] 28-May-14 9:05am    
Your query is not returning any data.... somewhere.
Uwakpeter 28-May-14 11:04am    
it returns data while testing on my computer, but doesnt return data if i deploy the application to another computer.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900