Fired when the control needs to obtain report parameters.

Namespace:  C1.Web.C1WebReport
Assembly:  C1.Web.C1WebReport.2 (in C1.Web.C1WebReport.2.dll)

Syntax

C#
public event DialogEventHandler InitializeParametersDialog
Visual Basic (Declaration)
Public Event InitializeParametersDialog As DialogEventHandler

Remarks

Reports that have a PARAMETERS clause in their RecordSource()()()() property allow users to provide report parameters.

C1Report displays a dialog where users may enter the report parameters. The C1WebReport control runs on the server and thus cannot show the parameter dialog. However, it will fire this event to allow event handlers to customize the parameters using code.

Examples

The following code uses the InitializeParametersDialog event to modify the values of the report parameters:

Copy CodeVisual Basic
PrivateSub C1WebReport1_InitializeParametersDialog(sender AsObject, e As C1.C1Report.DialogEventArgs)
    Dim p As C1.C1Report.ReportParameterCollection = e.Parameters
    p("Beginning Date").Value = Calendar1.SelectedDate
    p("Ending Date").Value = Calendar2.SelectedDate
EndSub
Copy CodeC#
privatevoid C1WebReport1_InitializeParametersDialog(object sender, C1.C1Report.DialogEventArgs e)
{
    C1.C1Report.ReportParameterCollection p = e.Parameters;
    p["Beginning Date"].Value = Calendar1.SelectedDate;
    p["Ending Date"].Value    = Calendar2.SelectedDate;
}

See Also