Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Disable ComboBox Item
Message
De
12/05/2008 21:02:24
 
 
À
12/05/2008 20:53:49
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Divers
Thread ID:
01316515
Message ID:
01316550
Vues:
11
Hi Perry,

I'd need to some other stuff to actually prevent them from selecting something that's "disabled", but this OwnerDraw stuff at least gives a visual indication of it being "disabled". I don't want to remove the items, I want them to show up, but look like they're disabled.

~~Bonnie



>I was going to reply before, after I looked it up and can only see the owner. But I haven't found any examples of enabling/disabling using it. Just changing the size of the item or the color. So it seems to be used more for display properties of drawing something rather then event properties, so to speak.
>
>Actually, here someone responds to this exact question, asking why you just wouldn't remove the disabled items from the list and just not display them:
>
>http://discuss.develop.com/archives/wa.exe?A2=ind0304c&L=dotnet-winforms&D=0&P=4465
>
>
>>>>Ha Ha Ha ... funny guy! You're sure a lot of help! <g>
>>>>
>>>
>>>Ok, you're right.
>>>
>>>How about:
>>>
>>>
>>>combo.Items[1].Enabled = false;
>>>

>>
>>Funny guy again! If it was that easy, I wouldn't have to ask. <g>
>>
>>I'm playing with the owner-drawn stuff right now. It's not a 100% good solution, but I'm trying to refine it a bit.
>>
>>~~Bonnie
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform