When using parameters in an ObjectDatasource for an RDLC report, how can you get the parameter values and display them in the report?
View Complete Post
I have 4 parameters in which 3 are passed in report and 1 is passed through report viewer. I have
made a parameter in SSRS called CandidateId to which I want to pass the value. The code for report viewer is:
intReportID = Convert.ToInt32(Request.QueryString["ReportID"
CandId = Convert.ToString(Session["CandidateId"
lblReportName.Text = dtReport.Rows["ReportName"
SSRSReportViewer.ServerReport.ReportServerCredentials = new
SSRSReportViewer.ProcessingMode = Microsoft.Reporting.WebForms.
SSRSReportViewer.ServerReport.ReportServerUrl = new
SSRSReportViewer.ServerReport.ReportPath = dtReport.Rows
Microsoft.Reporting.WebForms.ReportParameter theparams = new
theparams = new
theparams.Visible = false
Sorry couldn't think of any better Subject..
I am developing a User Reports Module using C#.Net using Visual Studio 2005. Basic purpose of this module is to allow user to be able to run their own Crystal Reports. i.e. if Users have their own Crystal Reports specific to their needs then we allow them to save them and view them from our user reports module.
So when user saves any report we save it on server and save the Physical path of that report in database. Now when user tries to view the report I get the location from database and load it. Which works ok. The issue now is those reports which have got parameters.
I am not saving any information about parameters in their reports. So I do not have any information about Report Parameters.
This same application exists in VB6. What that VB application does is opens the Crystal Report and then Crystal report asks for needed parameters exactly as it will do if we try to open a crystal report using crystal report and preview it from there it asks for parameter values. How can I do that in C#.Net.
VB has got code like this
I have the next table, & I have the Id of the account as a report parameter @AccountID
|account |LastYear |Jan |Feb |Mar |Apr |May |jun |Jul |Aug |Sep |Oct |Nov |Dec |YTD |Plan
| 00001 | 10.00 | 1 | 2 | 3 | 5 | 32 | 12 | 11| 10 | 8 | 87 | 54 | 54 | 123 | 250
I tried to build a Query that return me
Jan | 1
Feb | 2
Mar | 3 ...
I already tried to build a temporary table, but then Ignore my report parameter saying Must declare the scalar variable "@AccountID".
But If I eliminate the code of create #Table, The parameter works just fine.
Part of my query is :
Declare @IddeCuenta varchar(50)
set @IddeCuenta =
CREATE TABLE #VentasGraf
INSERT INTO #VentasGraf VALUES ('LstYear',0)
SET Informe_Ventas =
I have a report that is using Parameters. I found that when I have the same Available Value, then the report automatically changes the selection to the last Available Value in the list that matches the selected Value.
Parameter - @Selection
In this case, if I select 1, then the report automatically changes my selection to 5. If I select 2, the report automatically changes my selection to 6.
Does anyone have any ideas of how to keep the original selection?
Note: I assume people will next say, why have multiple Labels with the same value. The report I built is more complex than the example, but in any case the user needs to only select the Option for their area while they are not aware of what the Value is
equal that filters the report.
Hi, I'm getting stuck on what is probably a very simple/common task: Adding a textbox that displays the parameters that a user has selected for the current report.
For example, if the user chooses a @startdate and @enddate using date-pickers, a textbox in the header will display/print those parameters:
="Report by Department from " + @startdate+ " to " + @enddate
Seems simple, but I keep getting errors:
"Return statement in a Function, Get or Operator must return a value".
Can anyone help out with the proper syntax for repeating a user's parameters in the header or body of a report?
I have a Report, that I want to run ad-hoc from a Stored Procedure.
I want to render this report to PDF format, and save it to a drive.
The difference between this post and most threads I've seen is I don't want to run a stored proc within the report and send parameters to the stored proc.
I DO want to call a report FROM the stored proc, and send parameters TO the report.
How can I do this?