What about if you add a string field named ColourValue in your table that will keep the value of each colour as &HFFFFFF& for example???
I disagree with integer type... you can convert the type of the field if you need it in your code. You don't have to remove COLOR_DESC field because it makes you clear which value of colour corresponds to the proper colour. The what you will do is to retrieve the value of the field you want each time from your database and you will achieve it via a sql query for example select ColourValue from colours where Colour_Desc = "Blue" you will store the result of the query to a variable. You can use a combo box with the colours you want blue, green, white, etc and if you can compare the value of combobox with the result of query.
Private Sub combo_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles combo.SelectedIndexChanged
dim colour, tempColour as string
colour = combo.Items.Item(combo.SelectedIndex))
' here you will put your query and your code to open your recordset etc... I give you the query.
tempColour = 'select ColourValue from Colours where Colour_Desc=' & colour
System.Drawing.ColorTranslator.FromWin32(tempColour)
end sub
so you will get the colour you want each time without use if, or select case statement. Hope it helps. Have fun
![[dazed] [dazed] [dazed]](/data/assets/smilies/dazed.gif)