AdvantageCMS.Core.Common.BaseClasses Namespace
Build With Advantage

ToolControlBase..::..ProcessAction Method

Processes the specified CMS action (e.g., Save, Publish, Delete) for the current business object.

Namespace:  AdvantageCMS.Core.Admin.BaseClasses
Assembly:  AdvantageCMS.Core (in AdvantageCMS.Core.dll)

Syntax


public bool ProcessAction(
	eCMSActions toolAction,
	ActionArgs e
)

Parameters

toolAction
Type: AdvantageCMS.Core.Admin.Enums..::..eCMSActions
The CMS action to process.
e
Type: AdvantageCMS.Core.Admin.Event..::..ActionArgs
The action arguments providing context (user, SQL, domain, language).

Return Value

true if the action was processed successfully; false otherwise.

Examples


This method is sealed in ToolControl<(Of <(<'T>)>)> and should not be overridden directly. The framework calls SaveDataToObject()()()() and LoadDataFromObject(ActionArgs) at the appropriate points in the action lifecycle. Developers only need to override those two methods.
C#
// Do NOT override ProcessAction. Instead, override LoadDataFromObject and SaveDataToObject:
protected override void LoadDataFromObject(ActionArgs e)
{
    txtName.Text = MyObject.Name;
}

protected override void SaveDataToObject()
{
    MyObject.Name = txtName.Text;
}