Passing Parameters To DataSet Useb As Report Data Source
May 21, 2007
Hi guys,
How can I pass a parameter used for the DataSet query? I'm using this DataSet file as data source of my .rdlc report for Windows Forms.
I've already done a .rdlc report to Web Forms where I passed the query parameter by ObjectDataSource.SelectParameters, but in Windows Forms this object was not created. I just hava the following created objects:
- despesaTableAdapter (from myDataSetTableAdapter)
- despesaBindingSource (Windows.Forms.BindingSource)
- RelatorioDataSet (from myDataSet)
- relatorioDataSet1 (from myDataSet)
Any help will be very appreciated.
Tks and rgds,
Luis Antonio
View 1 Replies
ADVERTISEMENT
Nov 29, 2010
I am attempting to pass report parameters to my query. My report's data source is a WCF web service. I can run normal queries fine, but I have found that without the know-how to pass parameters to my query I am limited with my capabilities.
Assume a string parameter named "Name" with a specified default value of "Jmachol90", how would I pass that into the following query at the designated place:
 Â
<Query>
      <Method Namespace="http://schemas.microsoft.com/sqlserver/masterdataservices/2009/09" Name="SecurityPrincipalsGetRequest">
      <Parameters>
      <Parameter Name="Criteria" Type="XML">
<DefaultValue>
[code]....
View 17 Replies
View Related
Jul 16, 2009
I am building a webapp that calls an SSRS instance to display a report based on another servers web service.I can make a call from the ssrs server using this in the RDL:
<Query>
<Method Namespace="http://machine/webservices" Name="HelloUser">
               <Parameters>
                               <Parameter Name="user">
                               <DefaultValue>Craig</DefaultValue>
                               </Parameter>
               </Parameters>
</Method>
<ElementPath IgnoreNamespaces="true">*</ElementPath>
</Query>
This works no problem. but.. I want to have the user parameter "Craig" be a parameter passed in from the web app. If it were a regular SQL data source you would put @user in the query. How do you do it with XML text queries?
View 5 Replies
View Related
Jul 24, 2007
I have created a custom data extension.
I am using this custom data extension from BI Studio.
Que1: I want to create report parameters from BI studio and capture them in my Data Extension.
Que2: Every report parameter has so many properties, like hidden, internal, default value etc, how do capture that information in my data extension, the parameters only give me name and value.
Que3: I know I can capture command Text. So My command can be Select * From tablename where fieldname= @myFieldname. Once I get this commandText in my data extension, How do extract parameters of the command?
Que4: If I have any custom attributes in my RDL file, Can I capture them in my Data Extension ?
Any help is appreciated...
View 1 Replies
View Related
Oct 1, 2015
I have an MDX data-set query as follows: -
Member [Measures].[Measure3] As [Measures].[Value Rent Period Receipts]
Member [Measures].[Measure4] As (([Measures].[Value Rent Period Receipts]*-1)/[Measures].[Value Rent Period Debit])
Select {[Measures].[Measure1]
,[Measures].[Measure2]
,[Measures].[Measure3]
[Code] ....
There are two parameters; the value of lag passed to the LastPeriods function, and tenancy types passed in the where clause
I have a third parameter I would like to use called FirstDate and this I would like to pass to the LastPeriods function as the second argument
FirstDate is a value from my Time dimension, something like [Time].[Fiscal Time].[Sep. 15]
When editing the query to: -
Member [Measures].[Measure3] As [Measures].[Value Rent Period Receipts]
Member [Measures].[Measure4] As (([Measures].[Value Rent Period Receipts]*-1)/[Measures].[Value Rent Period Debit])
Select {[Measures].[Measure1]
,[Measures].[Measure2]
[Code] ....
The code errors. I have tried all sorts of formats such as  LastPeriods(@LagMonths,[@FirstDate]) and LastPeriods(@LagMonths,[Time].[Fiscal Time].[@FirstDate]), but nothing works
View 2 Replies
View Related
Apr 4, 2007
In the data tab of my report (Reporting Services for SQL Server 2000), I'd like to run a query that requires parameters be passed to it. Is there a way to pass the parameters of the report to that query?
Thank you.
View 3 Replies
View Related
Feb 13, 2008
I have three databases which have the identical data structure. When the user runs a report, he has to select a database.
For example, my report query would look like:
Select * from <theDatabase>.dbo.MyTable
How could I assign the value of <theDatabase> at run time depending on what the user selects from the list?
In my datasource, I have only specified the server name and no value for initial catalog.
View 1 Replies
View Related
Mar 10, 2008
I have an OLE DB Source that talks to an Oracle Db and returns back some data. I need to be able to pass some parameters to my query from the SSIS variables.
How can accomplish this ? Do I need to create a stored proc in my Oracle DB..is that the only way I can pass parameters ?
Is so how ?
Any examples would be really appreciated
Thanks
Smx
View 13 Replies
View Related
Jan 19, 2007
It's well known issue, that one can't use any dataset fields in a
report header/footer directly. One of the approach is to create
query-based parameter that basically equals
=First(Fields!@FieldName@.Value, "@DataSetName@") and use that
parameter value instead. But it doesn't work in my case!
My report displays some entity description and is parametrized with
EntityID param. Its header contains entity name that, according to the
approach, is queried from the data source through the EntityName
report parameter. There's important issue: the report is displayed in
ReportViewer control, that is embedded into my application and entity
ID parameter isn't ser by user in ReportViewer parameters area. Its
default value is changed by the application with SetReportParameters()
web method every time a user wants to view the report according to the
entity the user is exploring in the application. But after the report
has been rendered, its header always contains not actual (outdated)
entity name. Nevertheless, the report body contains actual data
(including entity name). If I alter entity ID parameter in ReportViewer
or in web-based Report Manager and refresh report, header displays
correct entity name.
What's wrong in the workflow described?
View 3 Replies
View Related
Oct 5, 2007
HI everyone;
i have a problem , is there a possible to pass a dataset to a ssrs report programmatically ?
or at runtime without specifying it at design time ...
View 1 Replies
View Related
May 28, 2007
I have many MS Access reports that process recordsets obtained from a MySQL database, based on a user-selected date range. This uses VBA and input boxes. I'm now creating .aspx pages to get the user input via the web, and am successful in creating a DataSet. My .aspx.vb code includes using Automation to open the Access report in Snapshot Viewer (DoCmd.OutputTo). How do I pass the DataSet to MS Access to replace using recordsets?
My VBA code in Access used to be this:
Code Snippet
Dim ws As Workspace
Dim strConnection As String
Dim dbs As Database
Dim rst_chg As Recordset
Set ws = DBEngine.Workspaces(0)
strConnection = "ODBC;DSN=xxx;DATABASE=xxx;" _
& "SERVER=10.1.144.xxx;" _
& "UID=xxx;PWD=xxx;PORT=xxx;OPTION=0;" _
& "STMT=set wait_timeout=100000;;"
Set dbs = ws.OpenDatabase("", True, True, strConnection)
Set rst_chg = dbs.OpenRecordset("SELECT ...")
'process the recordset ...
I'm thinking I should be able to eliminate most of this code and Set rst_chg = DataSet. I've been successful with using WriteXml in the .aspx.vb page and Application.ImportXML in my VBA to pass the data using XML, but this writes to the hard drive, and also creates a database in Access (overhead I would rather not have to deal with). Again, is there a way to open the DataSet directly in my VBA code?
Thanks,
Guy Rivers
View 1 Replies
View Related
Nov 18, 2007
Here is a situation in my company:
We have an Office SharePoint 2007 site, we developed a couple of web parts and added them to our site. We used SQL Server Reporting services 2005 as our reporting solution. The reports are hosted on the report center and when we need a report, we open it by sending a URL requesting the report, passing the report parameters in the URL query string. So the report is filtered based on the parameters passed from the web parts.
But since best practices say that you should host reports directly under SharePoint, by configuring the reporting services to run in the SharePoint integrated mode. We followed the steps and installed SharePointRS and we finally succeeded to publish the reports to a SharePoint folder, but we had a limitation: we are unable to pass the report parameters internally to the report hosted in SharePoint. If we passed them in the query string as the report center case, SharePoint neglects them totally.
So the question is: how can I pass parameters internally between a SharePoint web part and a SQL server 2005 reporting services report hosted in SharePoint?
View 1 Replies
View Related
Sep 16, 2015
I am trying to develop a report from cube,and it has one drill through report.when i click on sales amount field on main report,then it open the drill through report with details.Here i passed the **(category,subcat,product)parameters(Cascaded)** to drill through report in action part of main report.In my main report i have two columns .
columns are **Level**  and        **Salesamount**. Â
Values are like Â
**[-]category** Â Â Â Â Â Â Â **100**
  **[-]subcat**       **50**
     **product**      **30**
when i click on 100, parameters are passed & it open the detail report correctly, but when i click on 50,the values for subcat parameter is not getting values in detail report and same as the product also.
Here i used the expressions in parameter values
**pCategory**----iif(inscope(category),!fields.category.value,split(join(Parameters!category.value,","),","))
**psubcat**----iif(inscope(subcat),!fields.subcat.value,split(join(Parameters!subcat.value,","),","))
**pproduct**----iif(inscope(product),!fields.product.value,split(join(Parameters!product.value,","),","))
View 3 Replies
View Related
Mar 31, 2008
Hi,
Is it possible to use datatable/dataset as source to a report in Reporting Services. That is possible in e.g. Crystal Reports. I can only find Report Server Model and XML as non-database sources.
Best regards
Lars
View 10 Replies
View Related
May 31, 2007
Hi, I've read some threads in regards to passing report parameters through the 'URL' but I am struggling to fully understand. To keep things simple I have 1 report parameter, named par_pub which brings back either ww06 or ww07. What I require is to click on a hyperlink and it directs me to my report and then populates the par_pub paramerter with ww07.
I am trying the below
http://emp6/Reports/Pages/Report.aspx?ItemPath=%2fTest+Reports%2fIT+Dev%2fSales+Summary+Detail&prefixar_pub=%WW07%
The part in bold is the location + name of the report and the later is where I am trying to pass the parameter. Can anyone please help as this is not working.
Thanks
View 10 Replies
View Related
Nov 12, 2007
Hi,
I have a problem getting the URL string right to pass parameters from one report to another
This is the URL string I have set in the Navigation property of my text box:
"http://SQL/Reportserver$SQL2005/Pages/Report.aspx?%2fEarlyWarning2%2fratio+reports+-+test%2freport_upper_lower_benchmark_ratio1&rs:Command=Render&rcarameters=false
&company="&Parameters!company.Value.ToString()&Parameters!year.Value.ToString()&Fields!ratioName.Value.ToString()
The first thing is that when I just want to view the report say, with parameters hidden, I get this URL
http://reportserver/?%2fEarlyWarning2%2fratio+reports+-+test%2freport_upper_lower_benchmark_ratio1&rs%3aCommand=Render&rc%3aParameters=false
with the message "Internet Explorer cannot display the webpage"
Why does the first part of the URL change?
If I run it with just one parameter, company, I get the same error message with this URL :
http://reportserver/?%2fcompany.Value.ToString()&rs%3aCommand=Render&rc%3aParameters=false&company=%22
It looks like no value for the company parameter being passed
Any suggestions appreciated
Ruth
View 9 Replies
View Related
Feb 13, 2008
Hi,
I have created a report in VS 2003 using command type as Text for a stored procedure. The stored procedure itself takes in 2 parameters.
I have passed one of them in the exec statement but the other parameter is the one which I want to pass to the stored procedure through report.
So, in short, I have got this statement in dataset
EXEC SP1 1
Which means only 1 of the arguments is being passed to the stored procedure and not the second one. I would appreciate if some one can guide me on how to pass a report parameter to the stored procedure which using command type text
Cheers.
View 5 Replies
View Related
Aug 29, 2007
Hi. I've got a report I'm designing for the web using a ReportViewer control and an RDLC report file. Here's what needs to happen in the report,
The main report calls one stored procedure with some user provided parameters, which returns a dataset.
A sub-report will use 2 of the columns returned from the dataset above to call another stored procedure, which then provides the dataset used for the ReportViewer control.
I'm lost in trying to implement this. How do I call the first stored procedure to get the data? Then how do I pass the returned columns to the sub-report?
The main report will have a number of these sub-reports, each on its own page. I'm just trying to implement the first sub-report. Is there an easier way to implement this without using sub-reports? Thanks.
View 4 Replies
View Related
Jun 9, 2006
I'm currently trying to create a report that will take three parameters in the URL to generate a report: year, month, and day. The report is using an analysis services data source in RS 2005. Now, my problem is that the parameters being passed in the URL are not being selected in the drop down boxes for the parameters. The report does not throw any exceptions, and after the user selects values for the year, month, and day everything generates successfully.
Here is the URL format I am trying: http://localhost/ReportServer?/FolderName/ReportName&rs:Command=render&Year=2006&Month=6&Day=9
Currently, my parameters are all set to null for default values. They are also not multivalued, not internal, not hidden, don't allow blank, and don't allow null. I have also looked through the valid values in the drop down box for each parameter and verified that the values I supplied in the URL do exist. Also, the data types for each parameter is Integer just like the data type found in the database.
In my opinion, this problem seems directly related to using an analysis services data source. After I was getting this problem, I created a sample report using SQL Server data source, used the same three parameters, and passed them in the URL. Everything on that report worked perfectly.
Please help, I've looked thorugh almost every piece of documentation regarding parameters for Reporting Services and still no luck. Thanks!!
View 12 Replies
View Related
Feb 22, 2008
Hi All,
I want to dynamically generate the SQL Server Reporting Services by passing the query parameter from the url like this :
"http://localhost/Reports/Pages/Report.aspx?ItemPath=%2fDashboardReports%2fHorse_Profile&rs:Command=Render&rcarameters=false&HorseID=117415"
Where horseid id my parameter which is needed by report to generate the required data.
This query paramter value is picked from the text box on my jsp page.
But my problem is when i go to this url it says the message
"The 'HorseID' parameter is missing a value ".
In my report i have disabled the prompt user option , enable the Hide paramter option and has given no default value for this parameter.
I have done a lot of search on this topic. Everybody says that we can pass the values from the url like i am using. But still its not working. This forum is my last hope.
Any body has any idea please give me some idea.
Regards.
View 9 Replies
View Related
Apr 5, 2007
I'm currently trying to create a report that will take one parameters in the URL to generate a detail report. when i pass parameter as
http://marshad/ReportServer?/UpdatedByClickTest/S&rs:Command=Render&P1=123
it works fine . But i want to send master report's parameter to detail at run time which is selected in master report, then i got an error
i want to use
http://marshad/ReportServer?/UpdatedByClickTest/S&rs:Command=Render&P1=" &Parameters!p1.Value& "
but an error come i,e
" The path of the item '/UpdatedByClickTest/S,Parameters!p1.Value, "' is not valid. The full path must be less than 260 characters long, must start with slash; other restrictions apply. Check the documentation for complete set of restrictions. (rsInvalidItemPath)"
how can i pass parameter to remove this error?
plz any one help me i shall be thankfull to you
View 4 Replies
View Related
May 12, 2008
I am developing a report against OLAP. I have a main report and a sub report. The parameters to both are exactly the same. I am passing parameters to sub report from main. Whenever I use Field!Fieldname.Value as a parameter value to the sub report, I get an error saying one or more parameters required to run the report have not been specified. I used the UniqueName, but that doesnt do my grouping right ( I dont think this works for multi-value report)
I am lost...I need to figure this out ASAP. Does somebody know an article or do you know as how to deal with OLAP reports as sub reports and passing parameters as multi-value? I tried to attach the code, but I ran out of maximum characters...
View 4 Replies
View Related
Jul 3, 2007
Code Snippet
' DataSet element
writer.WriteStartElement("DataSets")
writer.WriteStartElement("DataSet")
writer.WriteAttributeString("Name", Nothing, "DataSet1")
' Query element
writer.WriteStartElement("Query")
writer.WriteElementString("DataSourceName", "DataSource1")
writer.WriteElementString("CommandType", "Text")
writer.WriteElementString("CommandText", m_commandText)
writer.WriteElementString("Timeout", "30")
writer.WriteEndElement() ' Query
writer.WriteStartElement("Parameters")
writer.WriteStartElement("Parameter")
writer.WriteAttributeString("Name", Nothing, "GlLayoutNo")
writer.WriteEndElement() ' Parameter
writer.WriteEndElement() ' Parameters
' Fields elements
writer.WriteStartElement("Fields")
Dim fieldName As String
For Each fieldName In m_fields
writer.WriteStartElement("Field")
writer.WriteAttributeString("Name", Nothing, fieldName)
writer.WriteElementString("DataField", Nothing, fieldName)
writer.WriteEndElement() ' Field
Next fieldName
' End previous elements
writer.WriteEndElement() ' Fields
writer.WriteEndElement() ' DataSet
writer.WriteEndElement() ' DataSets
In the above code, the XML parser does not understand the Parameters element. I've also tried ReportParameters as the name of the element. I don't seem to understand why, because in the SQL data tab, Parameters is a subelement of DataSet. Why am I getting this error and how do I programmatically specify that I want a report created on the fly to have parameters?
Deserialization failed: The element 'DataSet' in namespace 'http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition' has invalid child element 'Parameters' in namespace 'http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition'. List of possible elements expected: 'http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:Fields http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:Query http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:CaseSensitivity http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:Collation http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:AccentSensitivity http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:KanatypeSensitivity http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:WidthSensitivity http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition:Filters ##other:*'. Line 21, position 8.
View 1 Replies
View Related
Mar 13, 2008
Is it possible to get the reportdataset field values into parameters. dynamically when the report is generated.
Thanks.
View 1 Replies
View Related
Sep 15, 2007
Hi:
I am new to reporting services and wanted to see if anyone had any experience trying to do this...that "this" is passing a parameter to a report, but having the user fill in some others. I can pass all of my parameters to the report or let the user fill all of them in, but it doesn't seem to let me fill in one and have the users fill in the others.
Does anyone know if this is possible?
View 1 Replies
View Related
Aug 9, 2007
Hi,
From a aspx page I was able to Pass values (valid values) for the parameters to SSRS report 2005 which uses OLAP cube as datasource and got back the expectd result. but when I pass value other than a valid value i am getting ERROR message. do we always have to pass valid values only? any help is greatly appreciated.
Thanks,
Srik
View 7 Replies
View Related
Jun 16, 2006
I've created a line chart in my report which lists number of transactions by month. I've also created a report to list transactions by day. My goal is for the user to select a month and link the report to the graph with the selected month divided up into days (in other words, the user wants to see the number of transactions for each day in the selected month).
Anyway, everything is working perfectly except for one thing. In the list of parameters that I am passing to the report for each day, I want to pass a multivalue parameter which contains all the transaction IDs the user selected in creating the report (these are supplied by a multivalue parameter). However, in the parameter dialog box where it asks for a value to send to the awaiting parameter, I do not know how to supply more than one value. If I need to pass one value, it will work fine. However, I would like to do something like:
JOIN(Parameters!TransactionID.value, ",")
for the value of TransactionID, but when I generate the report it is not accepting the values. I'm pretty sure its just a format issue, and I just need to know how exactly I should pass these values.
I already understand that when passing multivalue parameters in a URL you need something like:
TransactionID=1&TransactionID=2
...in order to select multiple values. However, this is a slightly different situation. I'm really running out of ideas, so any help would be much appreciated.
Thank you guys so much
View 6 Replies
View Related
May 16, 2007
I have two subreports on one master report who's parameters @ReportDate would be set to the same date each time the report is run. When i run the master report i get an error for each report that tells me that one or more parameters required to run the report have not been specified. How do i pass the parameter i want to use in both reports from the master report through to the subreports.
Thanks again!
View 3 Replies
View Related
Dec 27, 2006
Hi
We are accessing reports through our web application. Our front end is implemented using tapestry
Our report is using four parameters. The report url is like
http://<servername>/ReportServer/Pages/ReportViewer.aspx?/<Report_Proj_Name>/<ReportName>
We are using POST requests with our report parameters defined as hidden variables.
If we use GET request, with parameters as query string then we are able to view our reports.
When I tried to access the report through web application, it gives out an error message as:
Reporting Services Error
--------------------------------------------------------------------------------
An attempt was made to set a report parameter 'formids' that is not
defined in this report. (rsUnknownReportParameter) Get Online Help
--------------------------------------------------------------------------------
For POST request, we get the above mentioned error. When I saw the view source I could see that tapestry
internally sets its own hidden variable for persisting its state in session.
formids is one of the hidden variable set by it.
How should I specify in the report that formids is not one of the report parameter.
There may be other hidden variables other than formids too that may get generated at runtime.
What setting should I do at the report end or at the application end?
Please help me find a solution for this problem.
Thanks!
View 2 Replies
View Related
Nov 13, 2007
Good morning all,
I have a report which is getting its parameters from an ASP.net page. My ASP developer wants to send in simple values, such as the list 1,2,3,4 for a parameter. However my report needs that list to look like [CD RSRC].[RSRC].&[1], [CD RSRC].[RSRC].&[2], [CD RSRC].[RSRC].&[3], [CD RSRC].[RSRC].&[4].
Is there any way, on the report services side, to capture an incoming report parameter, parse it, loop over the parsed values and format them?
I don't think there is, but I wanted to check before I go back to the developer and tell him he has to send in tuple lists.
Thanks,
Kathryn
View 1 Replies
View Related
Jul 4, 2007
All,
I have two reports. One is the main/summary report and other one is drill through. When I pass the Start and End Date parameters from main to the drill, the original format of DateTime changes. For example, in main report the data is displayed for following date range:
4/7/2007 - 5/9/2007 (i.e 4 July 2007 to 5 Sept 2007)
which displays correct data.
However, when I click on the drill through link, it jumps to the drill through report but displays data for the following period:
7/4/2007 - 9/5/2007 (i.e. 7 Apr 2007 to 9 May 2007)
The reporting services is converting the value from one format to another of the report parameters when passing them from parent report to the drill through. When run individually, these two reports display data for correct date range. And you can imagine, the child report crashes with rsReportParameterTypeMismatch error if the start or end date had a day part greater than 12 (e.g 25/4/2007).
I can't understand what could be going wrong. All the parameters in both reports are datetime, so intrisically, it shouldn't matter even if the reporting services is converting or using different date formats as long as the data type remains the same. Is there a way to fix this and force the parameters to stay in the format they are provided in the main report?
Your help is much appreciated.
Thanks.
View 5 Replies
View Related
Sep 29, 2015
So I have a report that uses an MDX query to fetch the main data for the tablix. Then I have a custom row added which pulls data in via a Lookup function and references a different dataset. The report has 3 parameters. Each dataset uses those 3 parameters in its underlying query. However, the dataset referenced in the lookup function doesnt seem to be updating when change the parameters and re-run the report.
View 2 Replies
View Related
Mar 13, 2008
hi ,
i am trying for a drill through report (rdlc)
ihave written the following code in drill through event of reportviewer, whenever i click on the first report iam getting the error like
An error has occurred during report processing.
A data source instance has no
t been supplied for the data source "DetailDS_get_orderdetail".
the code is
using System;
using System.Data;
using System.Data.SqlClient;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
//using Microsoft.ApplicationBlocks.Data;
using Microsoft.Reporting.WebForms;
using DAC;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
ReportViewer1.Visible = false;
}
protected void Button1_Click(object sender, EventArgs e)
{
DAC.clsReportsWoman obj = new clsReportsWoman();
DataSet ds = new DataSet();
ds = obj.get_order();
ReportViewer1.LocalReport.DataSources.Clear();
ReportDataSource reds = new ReportDataSource("DataSet1_get_order", ds.Tables[0]);
ReportViewer1.LocalReport.DataSources.Add(reds);
ReportViewer1.LocalReport.ReportPath = "C:/Documents and Settings/km63096/My Documents/Visual Studio 2005/WebSites/drillthrurep/Report.rdlc";
ReportViewer1.LocalReport.Refresh();
ReportViewer1.Visible = true;
}
protected void ReportViewer1_Drillthrough(object sender, DrillthroughEventArgs e)
{
DAC.clsReportsWoman obj = new clsReportsWoman();
ReportParameterInfoCollection DrillThroughValues =
e.Report.GetParameters();
foreach (ReportParameterInfo d in DrillThroughValues)
{
Label1.Text = d.Values[0].ToString().Trim();
}
LocalReport localreport = (LocalReport)e.Report;
string order_id = Label1.Text;
DataSet ds = new DataSet();
ds = obj.get_orderdetail(order_id);
ReportViewer1.LocalReport.DataSources.Clear();
ReportDataSource reds = new ReportDataSource("DetailDS_get_orderdetail", ds.Tables[0]);
ReportViewer1.LocalReport.DataSources.Add(reds);
ReportViewer1.LocalReport.ReportPath = Server.MapPath(@"Reportlevel1.rdlc");
ReportViewer1.LocalReport.Refresh();
}
}
the code in method get_orderdetail(order_id) is
public DataSet get_orderdetail(string order_id)
{
SqlCommand cmd = new SqlCommand();
DataSet ds = new DataSet();
cmd.Parameters.Add("@order_id", SqlDbType.VarChar, 50);
cmd.Parameters["@order_id"].Value = order_id;
ds = SQLHelper.ExecuteAdapter(cmd, CommandType.StoredProcedure, "dbo.get_orderdetail");
return (ds);
}pls help me.
View 1 Replies
View Related