We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Determine if selected and adding columns

Hi, I am switching out a Windows system DataGridView for your GridControl. I've run into a few little hiccups while trying to translate the already existing code. I have a function that determines if a cell is selected. The old code was simply:

If Me.GroupMembersView.Rows(row).Cells(i).Selected Then
Return True
End If

Is there a simple way to determine if a certain cell is selected with the GridControl?

In another part of the code I am programically adding columns in a for loop:

For i = 0 To Me.mGroupedSpecs.Count - 1
Me.GroupMembersView.Columns.Add("Task" + Me.mGroupedSpecs.ElementAt(i).SchTask.ID.ToString, "Task " + Me.mGroupedSpecs.ElementAt(i).SchTask.ID.ToString)
Me.GroupMembersView.Columns(i + FrozenCount).Width = 40
Next

I can't seem to figure out how to translate this for the GridControl.

I'd appreciate any help that you could give me! Thanks!

-Kelly


1 Reply

MC Mercy C Syncfusion Team January 9, 2012 01:38 PM UTC

Hi Kelly,

Thanks for your interest in Syncfusion products.

We couldn’t get your issue by the lines of code you gave. Could you please give us a simple sample that has DataGridView which would help us to understand better.

Please let us know if you have any concerns.

Regards,
Mercy.C



Loader.
Live Chat Icon For mobile
Up arrow icon