ToastNotification使用说明
显示效果
主要使用方法和属性
' You can also use other static properties on ToastNotification to customize toast appearance, like:
' ToastNotification.DefaultToastGlowColor - to change the default toast glow color
' ToastNotification.DefaultToastPosition - to change default toast position
'ToastNotification.ToastBackColor = Color.Red ' - to change the toast notification background color which is by default black
' ToastNotification.ToastForeColor - to change the toast notification text color which is by default white
' ToastNotification.ToastFont - to change the toast notification font
' ToastNotification.ToastMargin - to set spacing between edges of the toast and its parent form
' Also note that ToastNotification.Show has overload which allows you to specify the explicit toast position using X, Y coordinates
If CType(toastGlow.SelectedValue, eToastGlowColor) = eToastGlowColor.Custom Then
ToastNotification.CustomGlowColor = Color.FromArgb(48, customGlowColor.SelectedColor)
End If
Dim glow As eToastGlowColor = eToastGlowColor.Blue
If Not toastGlow Is Nothing Then
glow = CType(toastGlow.SelectedValue, eToastGlowColor)
End If
Dim pos As eToastPosition = eToastPosition.BottomCenter
If Not toastPosition.SelectedValue Is Nothing Then
pos = CType(toastPosition.SelectedValue, eToastPosition)
End If
ToastNotification.Show(Me, message.Text, IIf(checkBoxX1.Checked, My.Resources.win, Nothing), slider1.Value * 1000, glow, pos)