GrapeCity.Windows.SpreadSheet.UI Namespace > GcSpreadSheet Class : HighlightInvalidData Property |
'Declaration <System.ComponentModel.DefaultValueAttribute()> Public Property HighlightInvalidData As System.Boolean
'Usage Dim instance As GcSpreadSheet Dim value As System.Boolean instance.HighlightInvalidData = value value = instance.HighlightInvalidData
[System.ComponentModel.DefaultValue()] public System.bool HighlightInvalidData {get; set;}
gcSpreadSheet1.HighlightInvalidData = true; var valid = GrapeCity.Windows.SpreadSheet.Data.DataValidator.CreateListValidator("5,10,15,20"); gcSpreadSheet1.Sheets[0].Cells[0, 1].DataValidator = valid; gcSpreadSheet1.Sheets[0].Cells[0, 0].Text = "5, 10, 15, and 20 are valid numbers."; var valid1 = GrapeCity.Windows.SpreadSheet.Data.DataValidator.CreateNumberValidator(GrapeCity.Windows.SpreadSheet.Data.ComparisonOperator.GreaterThan, "5", "20", true); gcSpreadSheet1.Sheets[0].Cells[1, 1].DataValidator = valid1; gcSpreadSheet1.Sheets[0].Cells[1,0].Text = "A number greater than 5 is valid."; var valid2 = GrapeCity.Windows.SpreadSheet.Data.DataValidator.CreateTextLengthValidator(GrapeCity.Windows.SpreadSheet.Data.ComparisonOperator.GreaterThan, "4", "20"); gcSpreadSheet1.Sheets[0].Cells[2, 1].DataValidator = valid2; gcSpreadSheet1.Sheets[0].Cells[2, 0].Text = "Type more than four characters.";
GcSpreadSheet1.HighlightInvalidData = True Dim valid = GrapeCity.Windows.SpreadSheet.Data.DataValidator.CreateListValidator("5,10,15,20") GcSpreadSheet1.Sheets(0).Cells(0, 1).DataValidator = valid GcSpreadSheet1.Sheets(0).Cells(0, 0).Text = "5, 10, 15, and 20 are valid numbers." Dim valid1 = GrapeCity.Windows.SpreadSheet.Data.DataValidator.CreateNumberValidator(GrapeCity.Windows.SpreadSheet.Data.ComparisonOperator.GreaterThan, "5", "20", True) GcSpreadSheet1.Sheets(0).Cells(1, 1).DataValidator = valid1 GcSpreadSheet1.Sheets(0).Cells(1, 0).Text = "A number greater than 5 is valid." Dim valid2 = GrapeCity.Windows.SpreadSheet.Data.DataValidator.CreateTextLengthValidator(GrapeCity.Windows.SpreadSheet.Data.ComparisonOperator.GreaterThan, "4", "20") GcSpreadSheet1.Sheets(0).Cells(2, 1).DataValidator = valid2 GcSpreadSheet1.Sheets(0).Cells(2, 0).Text = "Type more than four characters."
Target Platforms: Windows 7, Windows 8 Desktop, Windows Vista SP1 or later, Windows Server 2000, Windows 2000 Professional, Windows XP Professional, Windows NT 4.0 Workstation, SP6, Windows NT 4.0 Server, SP6