Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How do I get rid of the third Checkbox state on a datagr
Message
General information
Forum:
ASP.NET
Category:
WebForms
Miscellaneous
Thread ID:
00871007
Message ID:
00871022
Views:
18
Is your underlying value null? If so, change it so the default value is 0.


>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
Previous
Reply
Map
View

Click here to load this message in the networking platform