Skip to main content

IServiceContainer.RegisterService(String, Object, Boolean) Method

Registers the specified service.

Namespace: DevExpress.Mvvm

Assembly: DevExpress.Mvvm.v23.2.dll

NuGet Packages: DevExpress.Mvvm, DevExpress.Win.Navigation

Declaration

void RegisterService(
    string key,
    object service,
    bool yieldToParent = false
)

Parameters

Name Type Description
key String

The service identifier.

service Object

The service to register.

Optional Parameters

Name Type Default Description
yieldToParent Boolean False

true to allow access to the passed service from the parent service container; otherwise, false.

Remarks

To learn more, see Services in custom ViewModels.

See Also