2

I have a WinForm using C# in my coding, and I use gridcontrol Devexpress 2010 to show the data contact list.

Here is my form

After selecting those lists I get the value from gridcontrol that I select and press the button OK to get it. I don't know the code.

Anyone can suggest me.

fatihyildizhan
  • 8,614
  • 7
  • 64
  • 88
aminvincent
  • 553
  • 1
  • 12
  • 43

1 Answers1

3

First of all i suggest you to the KB article: How to select rows via an unbound checkbox column

Starting with version 13.2, the GridView in the XtraGrid control provides a built-in checkbox column for multiple row selection. See the following help topic to learn more: Multiple Row Selection via Built-In Check Column

In versions prior to 13.2, you can use the following two methods to manually implement a column for row selection:

  1. Add a Boolean data column to your data source that will maintain the selected state of rows.
  2. Use an unbound grid column.

The first approach is easy to implement, but adding "dummy" columns to data is often forbidden due to the constraints of an application's business logic.

The second approach is clarified below.

Create an array that will store the selected states of rows. Create an Unbound Column whose values will be in sync with the array. Write a CustomUnboundColumnData event handler to get/set unbound column values.
See perfect example of this here:
DevExpress XtraGrid Control with checkBoxEdit column

References:
DevExpress Example:Multiple selection using checkbox (web style)

Hope this help..

Community
  • 1
  • 1
Niranjan Singh
  • 18,017
  • 2
  • 42
  • 75
  • that link is refers to devexpress 2013 and higher,..but i still didn't find tutorial for devexpress 2010....most of them give me some suggest that i must changing my devexpress version to devexpress 2013... – aminvincent Apr 02 '15 at 05:54