Поделиться через


ServiceManager.Subscribe Method (Type, SubscribeServiceCallback)

When overridden in a derived class, requests that the specified method is called when a service of the specified type is available.

Namespace:  Microsoft.Windows.Design
Assembly:  Microsoft.Windows.Design.Extensibility (in Microsoft.Windows.Design.Extensibility.dll)

Syntax

'Declaration
Public MustOverride Sub Subscribe ( _
    serviceType As Type, _
    callback As SubscribeServiceCallback _
)
public abstract void Subscribe(
    Type serviceType,
    SubscribeServiceCallback callback
)
public:
virtual void Subscribe(
    Type^ serviceType, 
    SubscribeServiceCallback^ callback
) abstract
abstract Subscribe : 
        serviceType:Type * 
        callback:SubscribeServiceCallback -> unit 
public abstract function Subscribe(
    serviceType : Type, 
    callback : SubscribeServiceCallback
)

Parameters

  • serviceType
    Type: System.Type
    The type of service to subscribe to.

Remarks

If the service is already available, this specified method is called immediately.

.NET Framework Security

See Also

Reference

ServiceManager Class

Subscribe Overload

Microsoft.Windows.Design Namespace

EditingContext

ContextItem

Unsubscribe

Publish

Other Resources

WPF Designer Extensibility