Report Script: Get object and value of a parameter

From AutoCount Resource Center


private AutoCount.Report.BaseReport __report;
private void Report_BeforePrint(object sender, System.ComponentModel.CancelEventArgs e) 
{
    __report = Report as AutoCount.Report.BaseReport;    
    
    //Name of the parameter is "parameter1"
    //__report.Parameters is Parameters.ParameterCollection
    object param1Value = __report.Parameters["parameter1"].Value;

    if (param1Value != null)
    {
        label22.Text = param1Value.ToString();
    }
    else
    {
        label22.Text = "null";
    }
}



Go to menu

Go to top
Resources For AutoCount Software Developers