WPF : Get index of clicked / selected cell on DataGrid -


how index of clicked / selected cell on datagrid ?
datagrid columns generated automatically , don't want use datatemplate .

        <datagrid          itemssource="{binding table,mode=twoway,updatesourcetrigger=propertychanged,isasync=true}" autogeneratecolumns="true">      </datagrid> 

datagrid x = (datagrid)this.findname("mydatagrid"); var index = x.selectedindex; 

there other usefull properties:

x.currentcolumn; x.currentitem; x.selecteditem; x.selectedvalue; 

Comments

Popular posts from this blog

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

html - How to style widget with post count different than without post count -

url rewriting - How to redirect a http POST with urlrewritefilter -