Spread Windows Forms 13.0 Product Documentation
FarPoint.Win.Spread Assembly / FarPoint.Win.Spread Namespace / MessageBoxNotify Class / Icon Property

In This Topic
    Icon Property (MessageBoxNotify)
    In This Topic
    Gets or sets the Icon.
    Public Property Icon As MessageBoxIcon
    Dim instance As MessageBoxNotify
    Dim value As MessageBoxIcon
    instance.Icon = value
    value = instance.Icon
    public MessageBoxIcon Icon {get; set;}

    Property Value

    The message icon. The default is System.Windows.Forms.MessageBoxIcon.None.
    The assigned value is not a valid System.Windows.Forms.MessageBoxIcon value.
    This example displays a message box for invalid values.
    //Type one of the candidate items in cell 1,1 to see the error notification
    FarPoint.Win.Spread.MessageBoxNotify cnotify = new FarPoint.Win.Spread.MessageBoxNotify();
    cnotify.Caption = "Error";
    cnotify.Message = "Invalid";
    cnotify.Icon = MessageBoxIcon.Question;
    FarPoint.Win.Spread.ExcludeListValidator excludelist = new FarPoint.Win.Spread.ExcludeListValidator();
    excludelist.Candidates = new string[] { "Bird", "Deer", "Squirrel", "Lizard" };
    fpSpread1.Sheets[0].AddValidators(new FarPoint.Win.Spread.Model.CellRange(1, 1, 1, 1), excludelist);
    'Type one of the candidate items in cell 1,1 to see the error notification
    Dim cnotify As New FarPoint.Win.Spread.MessageBoxNotify()
    cnotify.Caption = "Error"
    cnotify.Message = "Invalid"
    cnotify.Icon = MessageBoxIcon.Question
    Dim excludelist As New FarPoint.Win.Spread.ExcludeListValidator()
    excludelist.Candidates = New String() {"Bird", "Deer", "Squirrel", "Lizard"}
    FpSpread1.Sheets(0).AddValidators(New FarPoint.Win.Spread.Model.CellRange(1, 1, 1, 1), excludelist)
    See Also