Data retrieval failed for the subreport, 'Subreport1', located at

Posted Jan 01, 1970 12:00 AM

I am trying to get a subreport working. I am using VS 2010. I've inserted a "Subreport1" into my main report and keep getting the error: Data retrieval failed for the subreport, 'Subreport1', located at....

Here's my code:

public partial class rptEngOrd : Form
    public rptEngOrd()

    private List<EngOrd> eoNumParam;
    private string eonum;
    private DataSet dsReport;
    private DataSet dsSubReport;

    private void rptEngOrd_Load(object sender, EventArgs e)

    private void LoadComboBoxes()
            eoNumParam = EngOrdDB.GetDistinctEONum();
            cboEONum.DataSource = eoNumParam;
            cboEONum.SelectedIndex = -1;

        catch (Exception ex)
            MessageBox.Show(ex.Message, ex.GetType().ToString());

    private void btnPreview_Click(object sender, EventArgs e)

            if (cboEONum.SelectedValue.ToString().Equals("zALL"))
                eonum = "";
                eonum = cboEONum.SelectedValue.ToString();

            //get the data
            dsReport = EngOrdDB.GetEngOrdbyEONum(eonum);

            //provide local report information to viewer
            reportViewer1.LocalReport.ReportEmbeddedResource = "CustomMenu.rptEngOrd.rdlc";
            reportViewer1.ProcessingMode = ProcessingMode.Local;

            //prepare report data source
            ReportDataSource rds = new ReportDataSource();
            rds.Name = "dsReport";
            rds.Value = dsReport.Tables[0];

            //prepare sub report data source
            dsSubReport = EngOrdTaskDB.GetEngOrdTaskbyEONum(eonum);
            ReportDataSource rdsSub = new ReportDataSource();
            rdsSub.Name = "dsSubReport";
            rdsSub.Value = dsSubReport.Tables[0];
            reportViewer1.LocalReport.SubreportProcessing += new SubreportProcessingEventHandler(srptProcessingEventHandler);

            //load the report viewer


        catch (Exception ex)
            //display generic message back to user



    private void srptProcessingEventHandler(object sender, SubreportProcessingEventArgs e)
        ReportDataSource r = reportViewer1.LocalReport.DataSources[1];



Similar Topic Questions

Data retrieval failed for the subreport, Please check the lo

Please anybody can help me who have faced the same above problem while calling RDLC Subreport in winform. I have 2 tables 1) BankAccount & 2)BankAccountDetail. The relation between the two is by using bankCode field. Now I want to...

Posted Nov 30, -0001 12:00 AM

Data retrieval failed for the subreport, 'Subreport4', Only happened to 1 PC but not on other PCs

I have a VS2013 (written in C# x32) desktop application accessing a hosted SQL Server 2012. It has a report that has 4 subreports. After I installed it onto a few PCs, One of the PC has the above issue...

Posted Oct 31, 2014 1:45 AM

Do I need a database to save a finite set of data, and only for the current session in an ASP.NET MVC app?

I'm working on a calculator type app, three different views to perform three different types of calculations. For example purposes lets say it's just a multiplication table. I want to be able to enter the factors, have the products update, then...

Posted Jan 10, 2014 1:03 AM

ASP.NET IIS6, Forms authentication failed for the request. Reason: The ticket supplied was invalid

Some of you may be familiar with this error and I've tried fixes, i've been bashing my head up a brick wall at this the past day and need some help from someone, somewhere :) Situation: I've got a website that was...

Posted Mar 14, 2011 6:14 AM

Store data in session for the dynamically created HTMLAnchor tag

In my application , I have created HTMLAnchor class and HTMLImage class dynamically. So that they bind the data from sqlserver at runtime. The code as below, for (int i = 0; i < _dataset.Tables[0].Rows.Count; i++) ...

Posted Aug 20, 2014 10:27 AM

Selecting PHP data by date for the last 7 days from mysql database with a different date layout

I have a transactions table in my database where the date is stored in the date field like this: 2014-08-30 02:22:35. I'm making basic analytics and need to be able to display all transactions for each day for the last 7...

Posted Sep 13, 2014 2:44 AM

Where are the icons for the binding navigator located?

I am using a BindingNavigator in C# winforms I want to replace the navigation ToolStripButtons with my own BindableToolStripButtons But I need to keep the same icons When I drill into the image property of a navigation ToolStripButton I see that it is...

Posted Sep 15, 2014 11:47 AM

I want to get the data as zero for the date where data's are not present

Query: select logindate, count(*) as people from authortable group by logindate order by logindatedesc nulls last Output: logindate people 6-oct-2014 5 5-oct-2014 7 4-oct-2014 4 3-oct-2014 8 2-oct-2014 0 1-oct-2014 ...

Posted Oct 07, 2014 7:20 AM

Event code: 4005 Event message: Forms authentication failed for the request. Reason: The ticket supplied was invalid

When i was run my web application in everyday morning(after that issue was not reproduced),it was immediatly redirected to logout page while i perform any task after login.Session_end function was called unfortunately. Here i attach the main thread and...

Posted Oct 10, 2014 6:29 AM

Open Graph protocol: Which type of data to use for the article:author property?

I'm in the process of adding Open Graph meta tags to my blog article page. I'm not sure what type of data I should use for the article:author property. Would I use the author's username? the author's first name and surname? the...

Posted Oct 12, 2014 11:30 AM

Error Active report: No data provider found for the data provider type

I made a report with activeReport, I am connecting to dataSet, I drag fields in the report, but when I click on Preview to view the Report. I have this error:No data provider found for the data provider type. ...

Posted Nov 14, 2014 9:24 AM

How to pass own user data to check for the session

I am working on a group project where my group member is working on the user part while I am working in the post ads, view ads i.e. other parts of the project. I want to create fake users...

Posted Nov 14, 2014 5:11 AM

What technology does facebook uses for the multiple uploading images at once

I want to make a web application that will allow uploading many images at once but to work also on mobiles. I used html5, this works for IOS phones but on android doesn't work. If i look at facebook, they...

Posted Apr 04, 2014 5:54 AM

Confirmation message only for the Browser closing. Not at the time of window tab closed

I am trying to detect browser close button clicked by user. Hence I tried below code after searching in web := <head> <script type="text/javascript" src=""></script> <script> $(window).bind('click', function(event) { if( $(window).unbind('beforeunload'); }); $(window).bind('beforeunload',...

Posted Aug 05, 2014 1:57 AM

Request for the permission of type 'System.Data.OracleClient.OraclePermission failed when deploying on SharePoint 2010 web app

I am facing a permission issue. I am deploying my application to SharePoint 2010 environment as a WSP solution package. Our application uses Oracle client(which is deployed on the SharePoint Web Front End Servers) to contact our Oracle database...

Posted Aug 06, 2014 8:39 AM

"No data exists for the row/column" when connecting to SQL database from

I'm trying to create a program which has a datagridview, when the user clicks on a cell in the view, it then looks in a SQL database, grabs information from other fields in the same record, and automatically fills corresponding...

Posted Nov 20, 2013 1:15 AM

What's the minimum requirement for the DataSource property of ASPX server side data-bound controls?

I'm trying to trace back the minimum type requirement of a data source that can be assigned to the DataSource property of data-bound ASP.NET controls. I remember that I did this many times earlier every time with a few months or...

Posted Sep 05, 2013 3:28 AM

System.Data.SqlClient.SqlException: Login failed for user 'sumit'

I got this when i run my page plz help me Server Error in '/' Application. Login failed for user 'sumit'. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about...

Posted Nov 25, 2013 7:03 AM

Alternative method for pivot in sql for data retrieval

I am searching for an efficient method for horizontal aggregations in SQL other than pivot and case. What would be the best alternative method to create a pivot other than using groupby and orderby clauses. Let FV be a table containing...

Posted Nov 26, 2013 11:48 AM








Forgot Password
Reset my password!