Hi,
How to convert an RGB value to a long or a long to RGB?
Printable View
Hi,
How to convert an RGB value to a long or a long to RGB?
Try this!
Code:
'Add 1 Command Button to your form.
'Insert the following code to your form:
Private Sub Command1_Click()
r = Val(InputBox$("Red Value"))
B = Val(InputBox$("Blue Value"))
G = Val(InputBox$("Green Value"))
Lng$ = B * 65536 + G * 256 + r
MsgBox Lng$
End Sub
If you don't understand above example then try this demo!
http://www.buygold.net/v02n04/v02n04.html
I hope this helps you!