tags:

views:

8

answers:

0

hello All

i have a problem i have a Wpf data grid which have three item template image column i want to set the image source through cought behind how can i achive it i m unable to fetch my image inside column

my xaml code of grid is inside

plz help me`

                <my:DataGrid.Columns>
                    <my:DataGridTemplateColumn Header="Isprimary" Width="80" IsReadOnly="True" >
                        <my:DataGridTemplateColumn.CellTemplate >
                            <DataTemplate >
                                <RadioButton Name="rdisprimary"  IsChecked="{Binding Path=IsDefault, Mode=TwoWay }" 
                                         GroupName="isprimary"  
                                         Checked="rdisprimary_Checked" Margin="25,0,0,0"/>

                            </DataTemplate>

                        </my:DataGridTemplateColumn.CellTemplate>

                    </my:DataGridTemplateColumn>
                    <my:DataGridTemplateColumn Header="Edit" Width="50" IsReadOnly="True" >
                        <my:DataGridTemplateColumn.CellTemplate >
                            <DataTemplate>

                                <Image Name="imgEdit" Source="file:///D:\Projects\ChadCarpenter\AARFID\AARFID\Images\edit.png"
                                  Cursor="Hand"  MouseLeftButtonDown="imgEdit_MouseLeftButtonDown"/>
                            </DataTemplate>
                        </my:DataGridTemplateColumn.CellTemplate>
                    </my:DataGridTemplateColumn>

                    <my:DataGridTemplateColumn Header="Delete" Width="50" IsReadOnly="True"  >
                        <my:DataGridTemplateColumn.CellTemplate >
                            <DataTemplate>
                                <Image Source="file:///D:\Projects\ChadCarpenter\AARFID\AARFID\Images\remove.png" Cursor="Hand" MouseLeftButtonDown="Image_MouseLeftButtonDown"/>

                            </DataTemplate>


                        </my:DataGridTemplateColumn.CellTemplate>
                    </my:DataGridTemplateColumn>

                </my:DataGrid.Columns>


            </my:DataGrid>`