I found this code on the forum and it's working great, but I can't really understand its functionality. This code converts Color values as used by VB to HTML Colors (certain kind of Hexadecimal colors). Does somebody have a code that does the opposite; convert HTML Colors to VB understandable code?

Thx

[edit]o ****, posted it in Chit Chat... can a mod kick this to the VB General Questions?[/edit]

VB Code:
  1. Public Function ColorHTML(Number As Long) As String
  2. Dim MyString As String, MyNum As Long, MyCalc As Long, MyRemainder As Long, X As Integer
  3. MyRemainder = Number
  4.     MyString = ""
  5.     For X = 2 To 0 Step -1
  6.         MyCalc = MyRemainder \ 256 ^ X
  7.         MyString = Format$(Hex(MyCalc), "00") & MyString
  8.         MyRemainder = MyRemainder - MyCalc * 256 ^ X
  9.     Next
  10.     txtColor.Text = MyString
  11. End Function