0

I am using wpf notifyicon from this project: Codeproject link

I am having an issue while binding selectedItem of a listbox in popup with the viewmodel. Also, the tootip text background is black. please help me. i m having great trouble with the binding issue.

Below is a code snippet:

<ListBox ItemsSource="{Binding AppModules}" SelectedItem="{Binding SelectedModule, Mode=TwoWay}"/>

The listbox gets populated as expected, but the selected item binding is not working. Please help.

Victor Mukherjee
  • 10,487
  • 16
  • 54
  • 97
  • are you getting any exception in output window? – Nitin Aug 31 '13 at 07:04
  • not really, i found the issue, actually, i was using a control template for listboxitems which is a button in place of listboxitems. Now, when the button gets clicked, the bounded command gets fired, but selected item not changes. any idea how to do that? – Victor Mukherjee Aug 31 '13 at 07:07
  • can you send the commandparameter as CommandParameter = {Binding}. This should be the selected item. You can set the SelectedItem in the command handler – Nitin Aug 31 '13 at 07:17
  • if it solves your problem. can you update the question so that others so it can be used by others also. Thanks – Nitin Aug 31 '13 at 08:25

0 Answers0