Skip to main content

DXSplashScreenViewModel.Tag Property

Specifies the additional data associated with the view model instance.

Namespace: DevExpress.Mvvm

Assembly: DevExpress.Mvvm.v23.2.dll

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

Declaration

public object Tag { get; set; }

Property Value

Type Description
Object

An object that contains the additional data is associated with the view model instance.

Remarks

The example below illustrates how to pass a custom object to the splash screen:

SplashScreenManagerService.ViewModel = new DXSplashScreenViewModel() {
    Tag = new CustomDataSplashScreenViewModel() {
        Caption = "Custom Caption",
        Message = "Custom Message"
    }
};
SplashScreenManagerService.Show();



//...
public class CustomDataSplashScreenViewModel : ViewModelBase {
    public string Caption {
        get { return GetValue<string>(nameof(Caption)); }
        set { SetValue(value, nameof(Caption)); }
    }
    public string Message {
        get { return GetValue<string>(nameof(Message)); }
        set { SetValue(value, nameof(Message)); }
    }
}
<dx:WaitIndicator DeferedVisibility="True" Content="{Binding Path=.}">
    <dx:WaitIndicator.ContentTemplate>
        <DataTemplate>
            <StackPanel Orientation="Vertical">
                <TextBlock Text="{Binding Tag.Caption}" FontSize="20"/>
                <TextBlock Text="{Binding Tag.Message}"/>
            </StackPanel>
        </DataTemplate>
    </dx:WaitIndicator.ContentTemplate>
</dx:WaitIndicator>

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the Tag property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also