GrapeCity.Win.MultiRow Namespace > DomainUpDownCell Class : Sorted Property |
<SRCategoryAttribute("Behavior")> <DefaultValueAttribute()> <SRDescriptionAttribute("Indicates whether the item collection is sorted.")> Public Property Sorted As Boolean
Dim instance As DomainUpDownCell Dim value As Boolean instance.Sorted = value value = instance.Sorted
[SRCategory("Behavior")] [DefaultValue()] [SRDescription("Indicates whether the item collection is sorted.")] public bool Sorted {get; set;}
void setSortedButton_Click(object sender, EventArgs e) { DomainUpDownCell domainUpDownCell1 = this.gcMultiRow1[0, 0] as DomainUpDownCell; if (domainUpDownCell1.Sorted) { //set Sorted property from true to false, the items' sorted state cannot be restored to unsorted. domainUpDownCell1.Sorted = false; } else { //set it to true, the items change to the sorted state. domainUpDownCell1.Sorted = true; } label.Text = "Click the button, the items in the Items (7,3,5,1) property are sorted to (1,3,5,7)"; }
Private Sub setSortedButton_Click(ByVal sender As Object, ByVal e As EventArgs) Handles setSortedButton.Click Dim domainUpDownCell1 As DomainUpDownCell = TryCast(Me.gcMultiRow1(0, 0), DomainUpDownCell) If domainUpDownCell1.Sorted Then 'set Sorted property from true to false, the items sorted state cannot be restored. domainUpDownCell1.Sorted = False Else 'set it to true, the items change to the sorted state. domainUpDownCell1.Sorted = True End If label.Text = "Click the button, the items in the Items (7,3,5,1) property are sorted to (1,3,5,7)" End Sub
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2