Table of Contents

TTMSFNCWebPushDB.SetUserActiveState Method

Sets the active state for every subscription that belongs to the given user.

API unit family: TMS.TMSFNCWebPushDB Declaring type: TTMSFNCWebPushDB Inherited from: TTMSFNCCustomWebPushDB

Overloads

Overload 1

Sets the active state for every subscription that belongs to the given user.

procedure SetUserActiveState(AUserID: string; AActive: Boolean); overload;

Remarks

Requires both the user identifier and active-state fields to be active. Each change is applied only when the before-change event allows it.

Parameters

Name Description
AUserID User identifier whose records are updated.
AActive True marks the user as active and eligible to receive messages; False marks the user inactive.

Overload 2

Sets the active state for the subscription matching both the given user and browser identifiers.

procedure SetUserActiveState(AUserID, ABrowserID: string; AActive: Boolean); overload;

Remarks

Requires the user identifier, browser identifier, and active-state fields to be active. The change is applied only when the before-change event allows it.

Parameters

Name Description
AUserID User identifier to match.
ABrowserID Browser or device identifier to match.
AActive True marks the user as active and eligible to receive messages; False marks the user inactive.

Overload 3

Sets the active state for the subscription whose endpoint matches the supplied subscription.

procedure SetUserActiveState(ASubscription: TTMSFNCWebPushSubscription; AActive: Boolean); overload;

Remarks

Requires the active-state field to be active. The change is applied only when the before-change event allows it.

Parameters

Name Description
ASubscription Subscription whose endpoint identifies the record to update.
AActive True marks the user as active and eligible to receive messages; False marks the user inactive.