Results 1 to 6 of 6

Thread: Color obj

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Sep 2005
    Posts
    82

    Color obj

    (Noob quest) How do I add all the members of color (or pen) object to the list or combo box? Thanks in advance.
    Sanjay.

  2. #2
    I'm about to be a PowerPoster! kleinma's Avatar
    Join Date
    Nov 2001
    Location
    NJ - USA (Near NYC)
    Posts
    23,373

    Re: Color obj

    you are talking including system colors and web colors? or just colors like red, green, etc..??

  3. #3
    type Woss is new Grumpy; wossname's Avatar
    Join Date
    Aug 2002
    Location
    #!/bin/bash
    Posts
    5,682

    Re: Color obj

    VB Code:
    1. Dim c As Color
    2.         For i As Integer = 1 To 174
    3.             c = Color.FromKnownColor(CType(i, KnownColor))
    4.             ListBox1.Items.Add(c.Name)
    5.         Next i
    I don't live here any more.

  4. #4

    Thread Starter
    Lively Member
    Join Date
    Sep 2005
    Posts
    82

    Re: Color obj

    Yes kleinma,

    I want to add colors to the list.
    What abt system color and web colors?

    Sanjay

  5. #5
    PowerPoster
    Join Date
    Aug 2005
    Location
    College Station, TX
    Posts
    4,521

    Re: Color obj

    Are you trying to give the user options to choose colors?? If so, there is a ColorDialog control that has that ability already...

  6. #6

    Thread Starter
    Lively Member
    Join Date
    Sep 2005
    Posts
    82

    Re: Color obj

    Yah, I used that color dialog control, but just for query, I want to access the colors of color object.

    The code posted by wossname adds all the member to list, but how can i differentiate colors and other member?

    Sanjay

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width