I'm trying to achieve something like this:
[Subscribe(Dynamicweb.Modules.UserManagement.Notifications.UserOnBeforeSave)] public class UserOnBeforeSaveSubscriber : NotificationSubscriber { public override void OnNotify(string notification, NotificationArgs args) { if (args == null) return; Dynamicweb.Modules.UserManagement.UserNotificationArgs userArgs = (Dynamicweb.Modules.UserManagement.UserNotificationArgs)args; if (UserIsNotValidInRemoteSystem()) CancelTheUserCreation(); } }
Thanks.
Marco