c# - Button Enablity WPF -


i have usercontrol in have datadrid , in datagrid have 2 comboboxes. want when select item both comboboxes button outside datagrid should enabled.

my datagrid bind itemsource comboboxes.

i tries use mulidatatriggers failed button outside datagrid comboboxes not available it.

<datagrid>    <datagrid.columns>       <datagridtemplatecolumn width="auto">          <datagridtemplatecolumn.celltemplate>             <datatemplate>                <combobox name="combo1" itemssource="{binding lst1,mode=twoway,updatesourcetrigger=propertychanged}" displaymemberpath="code1" selectedvalue="{binding codeid1,mode=twoway,updatesourcetrigger=propertychanged}">                      <combobox name="combo2" itemssource="{binding lst2,mode=twoway,updatesourcetrigger=propertychanged}" displaymemberpath="code2" selectedvalue="{binding codeid2,mode=twoway,updatesourcetrigger=propertychanged}">             </datatemplate>          </datagridtemplatecolumn.celltemplate>       </datagridtemplatecolumn>    </datagrid.columns> </datagrid>  <button name="add" isenabled="{binding isaddenabled,mode=twoway,updatesourcetrigger=propertychanged}"/> 

there lot of answers question posted.

for example: enable text box when combobox item selected

the better way apply mvvm application.


Comments

Popular posts from this blog

php - Calling a template part from a post -

Firefox SVG shape not printing when it has stroke -

How to mention the localhost in android -