Solved

Report Viewer

Posted on 2014-01-16
4
555 Views
Last Modified: 2014-01-18
I am us vs2010 and I am trying to build a report viewer.  The initial generation of the page at load when opening the report viewer works fine.  Brings up the data needed correctly in every way.  I am trying to get the report to change based on a parameter change selection in a dropdown box on the page.  I get a message saying 'A data source instance has not been supplied for the data source 'DataSet1'.  

Below is the code.  I have tried to embed the data source, but obviously it is not working.

DataSet - ManualDataSet.xsd
Report  - ManDataReport.rdlc
ReportViewer - ManualDataReport.aspx

Can anyone help?

Thanks

Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        If Not IsPostBack Then
            DropDownList5.SelectedValue = "NC0117"
        End If

    End Sub


    Protected Sub DropDownList5_SelectedIndexChanged(sender As Object, e As System.EventArgs) Handles DropDownList5.SelectedIndexChanged
        Dim DieNumberParam(0) As Microsoft.Reporting.WebForms.ReportParameter
        DieNumberParam(0) = New Microsoft.Reporting.WebForms.ReportParameter("DieNumberParameter", DropDownList5.SelectedValue.ToString)

        ReportViewer1.Reset()
        ReportViewer1.LocalReport.ReportEmbeddedResource = "ManuaDataSet.xsd/ManDataReport.rdlc"
        ReportViewer1.LocalReport.ReportPath = "ManDataReport.rdlc"

        ReportViewer1.LocalReport.SetParameters(DieNumberParam)


    End Sub
0
Comment
Question by:rckrch
4 Comments
 
LVL 40

Accepted Solution

by:
Kyle Abrahams earned 500 total points
ID: 39788890
Please see this link with:
http://forums.asp.net/t/1960004.aspx?Dynamic+Report+Viewer+A+data+source+instance+has+not+been+supplied+for+the+data+source

Essentially it's looking for the datasource on rebind which you're not providing (I believe the reset clears it).
0
 

Author Closing Comment

by:rckrch
ID: 39791244
Thanks very much.  All I did was delete the reset statement and it works fine now.  Such a simple thing.  

Thanks very much.
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hi, I am very much excited today since I'm going to share something very exciting Tool used for Analytical Reporting and that's nothing but MICROSTRATEGY. Actually there are lot of other tools available in the market for Reporting Such as Co…
Hello, In my precious Article  (http://www.experts-exchange.com/Database/Reporting/A_15280-Create-Project-in-Microstrategy-Part-I.html)we saw the Configuration part for Microstrategy which included Metadata Creation and DataSource Preparation as …
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question