problem with GridDropDownColumn

2 posts, 0 answers
  1. mww
    mww avatar
    257 posts
    Member since:
    Sep 2012

    Posted 11 Nov 2008 Link to this post

    In my grid I have a drop down column

    <telerik:GridDropDownColumn UniqueName="ddlArtistType" DataField="ArtistType" ListTextField="ArtistType" ListValueField="ArtistType" 
                                            ListDataMember="ArtistType" HeaderText="Artist Type" DropDownControlType="RadComboBox" /> 

    When I run the page and add a new row, the items in the drop down list selection are taken from the underlying grid datasource not its own separate datasource (so many items in the dropdown are dupliacted)

    I need to assign a totally separate datasource in order to pick one of the items to enter into the underlying column in the grid

    Using the above method doesnt seem to make sense since when would you ever use the grid as a datasource for the dropdown, they are usually a totally different dataset

    Ive tried this
    <telerik:GridDropDownColumn UniqueName="ddlArtistType" DataField="ArtistType" HeaderText="Artist Type" DropDownControlType="RadComboBox" /> 

     and trying to populate in the ItemDataBound event, but the row always shows up empty

    So how can I use a GridDropDownColumn and assign its own datasource at runtime in my code behind ?

    ** Im not using a datatable as the grid datasource, im using a custom collection so ListDatamember would have no effect
  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 12 Nov 2008 Link to this post

    Hello Mark,

    You can go through the following link to understand how to customize the GridDropDownColumn.
    Customize/Configure GridDropDownColumn

  3. DevCraft R3 2016 release webinar banner
Back to Top