|
-
Jun 2nd, 2006, 08:28 AM
#1
Thread Starter
Lively Member
[RESOLVED] VB.Net:How to add all colors in listbox
hi can anybody do for me.
How to add all colors in dotnet color library in a listbox?
for example a listbox has
red
green
blue
yellow
...
..
how to read from the dotnet library?
-
Jun 2nd, 2006, 08:55 AM
#2
Re: VB.Net:How to add all colors in listbox
Goto Quantum Software ... get their Windows Forms Components ... it includes a Color drop down that you can use.... and it's free!
-tg
-
Jun 2nd, 2006, 09:57 AM
#3
Thread Starter
Lively Member
Re: VB.Net:How to add all colors in listbox
hi
i need the all colors in a array...
for example when we type "color. " then it shows all supported colors in dropdown list.
i want to store all of them into an array or a listbox
-
Jun 2nd, 2006, 10:54 AM
#4
New Member
Re: VB.Net:How to add all colors in listbox
hi softkans,
try this
At the top
Imports System.Reflection
and then ...
Dim properties As PropertyInfo() = GetType(System.Drawing.Color).GetProperties(BindingFlags.Static Or BindingFlags.Public)
Dim color As PropertyInfo
For Each color In properties
ListBox1.Items.Add(color.Name)
Next
please RESOLVED this post if u got the result
-
Jun 3rd, 2006, 01:50 AM
#5
Thread Starter
Lively Member
Re: VB.Net:How to add all colors in listbox
 Originally Posted by raibow
hi softkans,
try this
At the top
Imports System.Reflection
and then ...
Dim properties As PropertyInfo() = GetType(System.Drawing.Color).GetProperties(BindingFlags.Static Or BindingFlags.Public)
Dim color As PropertyInfo
For Each color In properties
ListBox1.Items.Add(color.Name)
Next
please RESOLVED this post if u got the result
ok raibow.. thanks
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|