WPF Conditional Binding. Button.IsEnabled to SelectedIndex >= 0

Posted by Chris Klepeis on Stack Overflow See other posts from Stack Overflow or by Chris Klepeis
Published on 2010-05-26T01:42:51Z Indexed on 2010/05/26 1:51 UTC
Read the original article Hit count: 1039

Filed under:
|
|
|

I want to bind a buttons IsEnabled property to (myObject.SelectedIndex >= 0).... isn't there a simple way to do this in the xaml (without having to do crazy things to any underlying objects)? I haven't really seen a good example.

Honestly, I wish this was as easy as Flex 3 ... I.E.:

<mx:Button enabled="{dataGrid.SelectedIndex >= 0}" ...

© Stack Overflow or respective owner

Related posts about wpf

Related posts about databinding