Gets or sets a string containing VBScript code to be executed before the Section is formatted.

Namespace:  C1.C1Report
Assembly:  C1.C1Report.2 (in C1.C1Report.2.dll)

Syntax

C#
[DefaultValueAttribute(null)]
public string OnFormat { get; set; }
Visual Basic
<DefaultValueAttribute(Nothing)> _
Public Property OnFormat As String
	Get
	Set

Remarks

This property contains VBScript instructions to be executed before the fields in the section are calculated. When this script is executed, the recordset already holds the data that will be displayed in the section, but the field values have not been updated yet.

Use this event to assign values to fields before they are calculated, so the new values will be taken into account when the control calculates the field's size and position when the CanGrow or CanShrink properties are set to true.

If you want to set field properties based on the field's current value, use the OnPrint property instead.

See Also