If I have a form which has a background colour of &H00C0C0C0 then it's easy to extract the RGB values. OK, but what if the colour of the form is taken from the current palette so the value is &H0800000F. How do I extract the value 15 from this ? Once I've got that I know how to get the RGB from the API but I'm no maths wizz so any help on getting the 15 from the value would be appreciated.