Click here to Skip to main content
16,007,610 members
Home / Discussions / C#
   

C#

 
GeneralRe: ListView problem Pin
datainjector12-Dec-03 7:52
datainjector12-Dec-03 7:52 
GeneralRe: ListView problem Pin
Heath Stewart12-Dec-03 8:36
protectorHeath Stewart12-Dec-03 8:36 
GeneralUsing Dropdownlist in Datagrid Pin
t_m2002052111-Dec-03 9:29
t_m2002052111-Dec-03 9:29 
GeneralRe: Using Dropdownlist in Datagrid Pin
Heath Stewart11-Dec-03 10:35
protectorHeath Stewart11-Dec-03 10:35 
GeneralComboBox DropDown Pin
Shaun Becker11-Dec-03 7:32
Shaun Becker11-Dec-03 7:32 
GeneralRe: ComboBox DropDown Pin
Not Active11-Dec-03 7:58
mentorNot Active11-Dec-03 7:58 
GeneralRe: ComboBox DropDown Pin
Shaun Becker11-Dec-03 8:23
Shaun Becker11-Dec-03 8:23 
GeneralRe: ComboBox DropDown Pin
Heath Stewart11-Dec-03 10:31
protectorHeath Stewart11-Dec-03 10:31 
You could try extending ComboBox, then override WndProc. For the CBN_DROPDOWN notification message (msg id 7), return instead of calling the base.WndProc:
protected override void WndProc(ref Message m)
{
  if (m.Msg == 7) return;
  base.WndProc(ref m);
}
That may stop it, but the documentation for that notification message doesn't mention how to stop it. By not passing the notification message to the ComboBox, though, it shouldn't display the popup window that represents the drop-down. It's worth a shot.

Also, you should consider making your own from scratch. If the above doesn't work, it's often easier making your own controls that trying to change existing ones. Remember that almost every control in System.Windows.Forms is just a wrapper class for their Windows Common Controls equivalent, so the true behavior of the control itself is defined by native code.

If you must make your own, I suggest you download something like .NET Reflector[^] to peer inside how the System.Windows.Forms.ComboBox works for things that aren't apparent in the documentation.

 

-----BEGIN GEEK CODE BLOCK-----
Version: 3.21
GCS/G/MU d- s: a- C++++ UL@ P++(+++) L+(--) E--- W+++ N++ o+ K? w++++ O- M(+) V? PS-- PE Y++ PGP++ t++@ 5 X+++ R+@ tv+ b(-)>b++ DI++++ D+ G e++>+++ h---* r+++ y+++
-----END GEEK CODE BLOCK-----
GeneralLooking for other controls in design-time Pin
f_popovic11-Dec-03 6:34
f_popovic11-Dec-03 6:34 
GeneralRe: Looking for other controls in design-time Pin
Heath Stewart11-Dec-03 10:23
protectorHeath Stewart11-Dec-03 10:23 
GeneralRe: Looking for other controls in design-time Pin
f_popovic12-Dec-03 0:17
f_popovic12-Dec-03 0:17 
GeneralRe: Looking for other controls in design-time Pin
Heath Stewart12-Dec-03 3:50
protectorHeath Stewart12-Dec-03 3:50 
GeneralRe: Looking for other controls in design-time Pin
f_popovic13-Dec-03 23:43
f_popovic13-Dec-03 23:43 
GeneralRe: Looking for other controls in design-time Pin
Heath Stewart14-Dec-03 5:36
protectorHeath Stewart14-Dec-03 5:36 
GeneralRe: Looking for other controls in design-time Pin
f_popovic14-Dec-03 21:33
f_popovic14-Dec-03 21:33 
GeneralApp.Config refresh Pin
RB@Emphasys11-Dec-03 5:10
RB@Emphasys11-Dec-03 5:10 
GeneralRe: App.Config refresh Pin
Guillermo Rivero11-Dec-03 7:17
Guillermo Rivero11-Dec-03 7:17 
GeneralRe: App.Config refresh Pin
Heath Stewart11-Dec-03 10:15
protectorHeath Stewart11-Dec-03 10:15 
GeneralC# HTTP Text Browser Pin
Guiro11-Dec-03 2:10
Guiro11-Dec-03 2:10 
GeneralRe: C# HTTP Text Browser Pin
Heath Stewart11-Dec-03 4:15
protectorHeath Stewart11-Dec-03 4:15 
GeneralRe: C# HTTP Text Browser Pin
Guiro12-Dec-03 2:57
Guiro12-Dec-03 2:57 
GeneralRe: C# HTTP Text Browser Pin
Heath Stewart12-Dec-03 3:51
protectorHeath Stewart12-Dec-03 3:51 
GeneralEnumerating Virtual Folders Pin
DotNetEvangelist11-Dec-03 2:04
DotNetEvangelist11-Dec-03 2:04 
GeneralRe: Enumerating Virtual Folders Pin
totig11-Dec-03 3:23
totig11-Dec-03 3:23 
General.NET IDE c# Pin
Hovel11-Dec-03 0:41
Hovel11-Dec-03 0:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.