Members

Technology Zones

IBM Learning Center

Articles

Hosted By

MaximumASP

Info

Rated
Read 9,613 times

Downloads

Related Categories

HTML COLOR Selector

Rollershade

This is a simple way of finding the html color code for any color, this can be very usefull to find a colours code quickly and efficently

First create a standard form and place the following objects on it;

a textbox named; text1
a button named; command1
and a common dialog control called 'colordlg'

Finally, put the following code in the command1_Click event

Private Sub Command1_Click()
colordlg.ShowColor

Dim Col As String, SootyR As String, SootyG As String, SootyB As String
Col = Hex(colordlg.Color)

Do Until Len(Col) = 6
Col = 0 & Col
Loop
SootyR = Mid(Col, 1, 2)
SootyG = Mid(Col, 3, 2)
SootyB = Mid(Col, 5, 2)
Text1.Text = Chr(34) & "#" & SootyB & SootyG & SootyR & Chr(34)
End Sub

I am 25 and live in west Sussex. I enjoy drinking and going out, but I also enjoy writing programs + creating websites in my free time. I play golf and ski.

One of my main intrests when not drinking ;) is programming , the tv can get boring as hell, i first started programming with HTML in 1996 ish and in early 1998 i started learning Visual Basic, i am now learning C#.NET frm Jan 2004. I have continued to learn and gain valuable knowledge from the vb diploma i have completed. While learning vb i became a member of this here Developerfusion.com which i have now become a Moderator at. Examples of my previous projects like WebEdit and EasyCSS can be found on my website.

Comments

  • My HTML Editor

    Posted by Primesghost on 25 Jul 2002

    I finished it a while ago, it was mainly just a project to see if I could do it. What I ended up doing was basically designing a clone of Notepad with a listbox on the left side. Listed on the left ar...

  • Posted by Rollershade on 25 Jul 2002

    so hows the html editor going??

    im working on mine at the moment aswell

  • It really works

    Posted by Primesghost on 06 Mar 2002

    :) This works perfectly, and was exactly what I was looking for to help with the HTML editor I'm designing, thanx.