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

GridViewComboBox display images

1 Answer 46 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Chen
Top achievements
Rank 1
Chen asked on 30 Sep 2013, 01:28 AM
<telerik:GridViewComboBoxColumn  Header="2"
                                                 Width="50"
                                                 IsFilterable="False"
                                                 IsComboBoxEditable="True"
                                                 HeaderTextAlignment="Center"
                                                 DisplayMemberPath="CODE"
                                                 SelectedValueMemberPath="ID"
                                                 ItemsSource="{StaticResource  DutyCodeList}"
                                                 DataMemberBinding="{Binding NO2,Mode=TwoWay}"
                >
                </telerik:GridViewComboBoxColumn>
Hi,All

I met a problem,just like XAML codes I  pasted.
       The ItemsSource of column is StaticResource just like {"ZD","ZDM","ZN"} 
       Now I want to display the corresponding image which already exists in project directory in display model
       and display character list in edit model.


       Please help me out , if possible with code
       
       With Regards

      Chen Junning


        

1 Answer, 1 is accepted

Sort by
0
Dimitrina
Telerik team
answered on 30 Sep 2013, 10:44 AM
Hello Chen,

In order to have an image displayed in view mode, you can redefine the CellTemplate for the column. For example you can check our online documentation here.

Then place an image and bind it to the path of the image, you can use an IValue Converter to return the exact path for the Binding. Please note that you should set the Binding to the same property you have bound the column to: "NO2".

I hope this helps.

Regards,
Didie
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for SILVERLIGHT.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Tags
GridView
Asked by
Chen
Top achievements
Rank 1
Answers by
Dimitrina
Telerik team
Share this question
or