WinUIMessageBoxService

  • 2 min to read

The WinUIMessageBoxService implements the IMessageBoxService interface and uses the WinUIMessageBox control to display messages.

WinUIMessageBox

NOTE

The message box stretches to fit the window's width when you use the WinUIMessageBoxService.

Example

You can use the WinUIMessageBoxService instead of the DXMessageBoxService. The following example demonstrates how to use the WinUIMessageBoxService:

Imports DevExpress.Mvvm
Imports System.Windows.Input

Namespace Example.ViewModel
    Public Class MainViewModel
        Protected Overridable ReadOnly Property MessageBoxService() As IMessageBoxService
            Get
                Return Nothing
            End Get
        End Property
        Public Sub ShowMessage()
            MessageBoxService.Show("This is MainView!")
        End Sub
    End Class
End Namespace