Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How do I get rid of the third Checkbox state on a datagrid?
Message
General information
Forum:
ASP.NET
Category:
WebForms
Title:
How do I get rid of the third Checkbox state on a datagrid?
Miscellaneous
Thread ID:
00871007
Message ID:
00871007
Views:
55
I have the following code for setting up one of the columns for a datagrid:
Dim OtherCorrespondenceCol As New DataGridBoolColumn
OtherCorrespondenceCol.MappingName = "OtherCorrespondence"
OtherCorrespondenceCol.HeaderText = "Other " & ControlChars.CrLf & "Correspondence"
OtherCorrespondenceCol.Width = 95
OtherCorrespondenceCol.AllowNull = False
OtherCorrespondenceCol.FalseValue = False
OtherCorrespondenceCol.TrueValue = True
gridStyle.GridColumnStyles.Add(OtherCorrespondenceCol)
The grid loads fine with existing information. However, when I click on the grid to add a new row, the default value for the checkbox is the greyed out state ("third state"). I want it to default to be not selected (False/0).

What am I missing to make it so the "third state" is not an option? Once I select the checkbox on datagrid, it never allows you to go back to the "third state". Once you have selected it, you can only alternate between checked and unchecked.

Thanks,

Vic
Next
Reply
Map
View

Click here to load this message in the networking platform