PC Review


Reply
Thread Tools Rate Thread

Combo and checkbox

 
 
GoGs
Guest
Posts: n/a
 
      24th Feb 2007
How can put checkBox in comboBox...


Thanks
--
GoGs
 
Reply With Quote
 
 
 
 
=?ISO-8859-2?Q?G=F6ran_Andersson?=
Guest
Posts: n/a
 
      24th Feb 2007
GoGs wrote:
> How can put checkBox in comboBox...
>
>
> Thanks
> --GoGs


You can't. You have to build your own combobox for that.

What would a checkbox in a combobox be used for anyway?

--
Göran Andersson
_____
http://www.guffa.com
 
Reply With Quote
 
GoGs
Guest
Posts: n/a
 
      24th Feb 2007
On Sat, 24 Feb 2007 13:21:25 +0100, Göran Andersson <(E-Mail Removed)>
wrote:

> GoGs wrote:
>> How can put checkBox in comboBox...
>> Thanks
>> --GoGs

>
> You can't. You have to build your own combobox for that.


Hmmm, How? Any tutorial?

>
> What would a checkbox in a combobox be used for anyway?


to save space...

>




--
GoGs
 
Reply With Quote
 
Laurent Bugnion [MVP]
Guest
Posts: n/a
 
      24th Feb 2007
Hi,

GoGs wrote:
> How can put checkBox in comboBox...
>
>
> Thanks
> --GoGs


Use WPF

<ComboBox>
<CheckBox>
Hello
</CheckBox>
</ComboBox>

HTH,
Laurent
--
Laurent Bugnion [MVP ASP.NET]
Software engineering, Blog: http://www.galasoft-LB.ch
PhotoAlbum: http://www.galasoft-LB.ch/pictures
Support children in Calcutta: http://www.calcutta-espoir.ch
 
Reply With Quote
 
Otis Mukinfus
Guest
Posts: n/a
 
      24th Feb 2007
On Sat, 24 Feb 2007 13:21:25 +0100, Göran Andersson <(E-Mail Removed)> wrote:

>GoGs wrote:
>> How can put checkBox in comboBox...
>>
>>
>> Thanks
>> --GoGs

>
>You can't. You have to build your own combobox for that.
>
>What would a checkbox in a combobox be used for anyway?


I think the OP wants a ComboBox with the same functionality as CheckedListBox,
but as you say there is no such thing as a CheckedComboBox. In fact, I don't
believe I've ever seen a ComboBox used in that way. It wouldn't make much
sense, would it?

Good luck with your project,

Otis Mukinfus

http://www.otismukinfus.com
http://www.arltex.com
http://www.tomchilders.com
http://www.n5ge.com
 
Reply With Quote
 
Morten Wennevik [C# MVP]
Guest
Posts: n/a
 
      24th Feb 2007
On Sat, 24 Feb 2007 13:33:28 +0100, GoGs <(E-Mail Removed)> wrote:

> On Sat, 24 Feb 2007 13:21:25 +0100, Göran Andersson <(E-Mail Removed)>
> wrote:
>
>> GoGs wrote:
>>> How can put checkBox in comboBox...
>>> Thanks
>>> --GoGs

>>
>> You can't. You have to build your own combobox for that.

>
> Hmmm, How? Any tutorial?
>


You have to use OwnerDraw and paint the checkboxes yourself as well as handle code for checking the box when a user selects the item.

The principle is the same as this article, but the drawing will be different. You have to draw the checkboxes, either manually or as an image.


http://www.csharphelp.com/archives/archive280.html

>>
>> What would a checkbox in a combobox be used for anyway?

>
> to save space...
>


Wouldn't a button opening a properties window be better?


--
Happy coding!
Morten Wennevik [C# MVP]
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Checkbox & Combo Box help Sweetpea Microsoft Excel Programming 4 18th Jul 2006 03:03 AM
Checkbox in combo box =?Utf-8?B?ZWIxbW9t?= Microsoft Access 2 16th Jul 2006 08:21 PM
Combo or Checkbox SMERTZ Microsoft Excel Programming 5 5th Feb 2006 02:50 PM
Using checkbox instead of combo =?Utf-8?B?U2NvdHQgQQ==?= Microsoft Access Form Coding 1 10th Mar 2005 05:12 PM
Checkbox with combo Anne Microsoft Access Form Coding 4 9th Sep 2004 10:23 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:43 PM.