i have read numerous posts and it appears as if i am doing this correctly, but i cannot get it to work. i am trying to pass 3 parameters to a stored proc used within my report. i use a class library for my report. i can run it in the designer fine, but when trying to execute from my application i get:
"procedure or function 'rpt_unpaidregistrations' expects parameter @OrganizationKey, which was not supplied.
if i put in a breakpoint on report1, i can see my parameters, and, after this code executes, their values. what am i missing?
as another question, in the class library when you are setting up the report, there seem to be 2 places where you can specify parameters. in the report itself AND within the SQLDataAdapter. running within the class library, i don't seem to need to ones at the report level. when are these needed, if at all?
thanks...
Me.ReportViewer1.Report = New rptUnpaidRegistrations
Dim report1 As Telerik.Reporting.Report = Me.ReportViewer1.Report
report1.ReportParameters(0).Value =
CInt(currentUser.OrganizationKey)
report1.ReportParameters(1).Value =
CInt(seasonKey)
report1.ReportParameters(2).Value =
CInt(leagueKey)
Me.ReportViewer1.Report = report1
<
script type="text/javascript">
function
PrintScoringList()
{
<%=ReportScoringList.ClientID %>.Print();
}
function
PrintScoringResults()
{
alert(
"Now,We will print Scoring Results");
<%=ReportScoringResult.ClientID %>.Print();
}
</
script>
and now about problem:
PrintScoringResults I call after programmaticaly binding results after this I call PrintScoringList but report printing ScoringResults(the anothe object)
Where I err?
Thanks ahead,Sergey!
On my report I have text box - Age(). How I can to run below function:
public
string CalculateAge()
{
DateTime BirthDate = DateTime.Now;
int years = DateTime.Now.Year - BirthDate.Year;
// subtract another year if we're before the
// birth day in the current year
if ((DateTime.Now.Month < BirthDate.Month && (BirthDate.Month - DateTime.Now.Month) >= 6))
years--;
return years.ToString();
}
as User functions for value the text box