c# - Mouse Double Click DataGrid row -


i have datagrid style template wish add double click behaviour to. binding should correct cannot seem xaml compiling / working.

all objects added idictionary must have key attribute or other type of key associated them.

what wrong code below?

<style targettype="{x:type datagridrow}">     <eventsetter event="mousedoubleclick" handler="{binding connect}"/> 

update per viktor's comment (gives exact same error):

<style x:key="datagridrowstyle" targettype="{x:type datagridrow}">     <eventsetter event="previewmousedoubleclick" handler="{binding connect}"/> 

one can use datagrid inputbindings achieve goal:

<datagrid.inputbindings>    <mousebinding mouseaction="leftdoubleclick" command="{binding somecommand}" /> </datagrid.inputbindings> 

Comments

Popular posts from this blog

php - cannot display multiple markers in google maps v3 from traceroute result -

php - Boolean search on database with 5 million rows, very slow -

css - Text drops down with smaller window -