protected override void Execute(NativeActivityContext context) { BookmarkScope scope = this.Scope.Get(context); if (scope == null) { throw FxTrace.Exception.AsError(new InvalidOperationException(System.Activities.SR.CannotUnregisterNullBookmarkScope)); } if (scope.Equals(context.DefaultBookmarkScope)) { throw FxTrace.Exception.AsError(new InvalidOperationException(System.Activities.SR.CannotUnregisterDefaultBookmarkScope)); } context.UnregisterBookmarkScope(scope); }
protected override void Execute(NativeActivityContext context) { BookmarkScope toUnregister = this.Scope.Get(context); if (toUnregister == null) { throw Microsoft.CoreWf.Internals.FxTrace.Exception.AsError(new InvalidOperationException(SR.CannotUnregisterNullBookmarkScope)); } if (toUnregister.Equals(context.DefaultBookmarkScope)) { throw Microsoft.CoreWf.Internals.FxTrace.Exception.AsError(new InvalidOperationException(SR.CannotUnregisterDefaultBookmarkScope)); } context.UnregisterBookmarkScope(toUnregister); }
protected override void Execute(NativeActivityContext context) { BookmarkScope toUnregister = this.Scope.Get(context); if (toUnregister == null) { throw SA.FxTrace.Exception.AsError(new InvalidOperationException(SA.SR.CannotUnregisterNullBookmarkScope)); } if (toUnregister.Equals(context.DefaultBookmarkScope)) { throw SA.FxTrace.Exception.AsError(new InvalidOperationException(SA.SR.CannotUnregisterDefaultBookmarkScope)); } context.UnregisterBookmarkScope(toUnregister); }