CreateObjectChangeArgs(TabSheet: ITabSheetBox; Object: ITabObject; Type: TabObjectChangeType);
TabSheet. The component, for which an event is generated.
Object. An object, for which an event is generated.
Type. Type of change that occurs with an object.
The CreateObjectChangeArgs constructor creates an argument of the event that occurs on changing an object.
By default event arguments are generated automatically on occurring an event. A constructor is required for manual calling the event. For details about manual event generation see the Manual Generation of Events section.
Executing the example requires a form containing the components:
TabSheetBox with the TabSheetBox1 identifier. A handler for the OnAfterObjectChange event should be assigned for the component.
UiReport with the UiReport1 identifier that is a data source for TabSheetBox1. UiReport1 should also be active and contain a loaded regular report with shapes on an active sheet.
Sub UserProc;
Var
Tab: ITabSheet;
Object: ITabObject;
Argument: TabObjectChangeEventArgs;
Begin
Tab := TabSheetBox1.Source.GetTabSheet;
Object := Tab.Objects.Item(0);
Argument := New TabObjectChangeEventArgs.CreateObjectChangeArgs(TabSheetBox1, Object, TabObjectChangeType.Angle);
TabSheetBox1.OnAfterObjectChange(TabSheetBox1, Argument);
End Sub UserProc;
After executing the example the procedure calls the OnAfterObjectChange event in the TabSheetBox1 component.
See also: