Solved

Report Viewer

Posted on 2014-01-16
4
566 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
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

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

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 …
I recently went through setting up a JasperReports Server using the AWS EC2 instance, and this article will cover some basic administration tasks I had to perform.
Come and listen to Percona CEO Peter Zaitsev discuss what’s new in Percona open source software, including Percona Server for MySQL (https://www.percona.com/software/mysql-database/percona-server) and MongoDB (https://www.percona.com/software/mongo-…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

707 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