cjard
Well-known member
- Joined
- Apr 25, 2006
- Messages
- 7,081
- Programming Experience
- 10+
I've noticed something slightly puzzling.
I have a menu on my form with a textbox embedded on the menu (ToolStripTextBox) and i have another TextBox on the main form panel. Both have a .Text property that are bound to SomeSetting - a setting string in the user settings. The binding is correct and the text of the setting shows in both boxes when starting the app. Annoyingly, when I edit the TextBox.Text, the SettingChanged event fires, but when I edit the ToolStripTextBox.Text, the settings changed event does not fire and indeed, the new contents of the TSTextBox are not written into the settings area.
Can anyone explain the quirky behaviour? For now I think I will attach an event handler to the TSTextBox.TextChanged event and set the setting myself, but it shouldnt be necessary?
I have a menu on my form with a textbox embedded on the menu (ToolStripTextBox) and i have another TextBox on the main form panel. Both have a .Text property that are bound to SomeSetting - a setting string in the user settings. The binding is correct and the text of the setting shows in both boxes when starting the app. Annoyingly, when I edit the TextBox.Text, the SettingChanged event fires, but when I edit the ToolStripTextBox.Text, the settings changed event does not fire and indeed, the new contents of the TSTextBox are not written into the settings area.
Can anyone explain the quirky behaviour? For now I think I will attach an event handler to the TSTextBox.TextChanged event and set the setting myself, but it shouldnt be necessary?