This is a migrated thread and some comments may be shown as answers.

Diffrent datasource for every rows in GridView.

3 Answers 81 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Marcin
Top achievements
Rank 1
Marcin asked on 03 Jan 2011, 09:55 AM
Hello,
I have problem with using two datasource in one column in my grid. I have two columns:
- column to choose type of number
- column GridViewComboBoxColumn with numbers binded to datasource
User in every rows can choose type and number from next column, I have two data source with numbers A, and number B. Can I define datasource for any rows? Someone implemented this mechanism ?
I use Q2 2010. 

Thanks for help
   Marcin

3 Answers, 1 is accepted

Sort by
0
Emanuel Varga
Top achievements
Rank 1
answered on 03 Jan 2011, 11:28 AM
Hello Marcin,

Can you please be a little more clear on this one?

What exactly are you trying to accomplish here? You want based on selection from column A to change the data in column B?
So let's say if the user selects 1 from column A, the available selection from column B to be let's say a,b,c
and if the user selects 2 from A, the selection in B to be d,e,f?

Something like this? (cascading dropdowns?)

Best Regards,
Emanuel Varga
Telerik WinForms MVP
0
Marcin
Top achievements
Rank 1
answered on 03 Jan 2011, 11:41 AM
Yes, your describe is correct:
 - column 1 to choose type of numer (two types AK and EK)
 - column 2 to choose number:
     a) if selected AK: datasource is dictionary with items a,b,c
     b) if selected EK: datasource is dictionary with items d,e,f
User can define this for every rows, f.e:

 Id      Type      Number
  1       AK           b
  2       EK           f
  3       AK           a

Marcin
0
Accepted
Richard Slade
Top achievements
Rank 2
answered on 03 Jan 2011, 11:43 AM
Hello,

Pelase have a look at this forum post which should help
Regards,
Richard
Tags
GridView
Asked by
Marcin
Top achievements
Rank 1
Answers by
Emanuel Varga
Top achievements
Rank 1
Marcin
Top achievements
Rank 1
Richard Slade
Top achievements
Rank 2
Share this question
or