We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

DataGrid ComboBox to cause TextBox enable/disable

Thread ID:

Created:

Platform:

Replies:

11359 Mar 3,2004 09:00 AM Windows Forms 0
loading
Tags: FAQ
Kevin Hector
Asked On March 3, 2004 09:00 AM

Hi. I have implemented the custom ComboBox column as described in the FAQ which accepts a delegate to notify subscribers of "selected index changed" events. I have also implemented the TextBox which fires the CheckEnable event during repaints to set it's enabled/disabled status. My problem is that when the user selects a new value in the ComboBox I need the TextBoxes to set their enabled/disabled state immediately according to the selection in the ComboBox. At the moment I have got them to do this when focus moves away from the ComboBox, but this is not quite the behaviour I was after. I have tried invalidating the DataGrid to force a repaint but this does not work. I have also tried reading the value of the ComboBox during the CheckEnabled event handler but this simultaneously affects ALL TextBoxes in the DataGrid. Any other suggestions? Also, can anyone recommend a book that goes into the kind of detail required to do this kind of work? I haven't seen anything even remotely as detailed as the excellent FAQ on this site. Thanks Kevin Hector

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;