Convert text to number

In my application I want to change the background color depending on the value of the text in the label.
for that i need to convert text to a decimal number so that i can use make color instruction.
Please help me/


Let me you want to convert "red" to -65536?

no I want to change background color of my label depending on the value of the text in the lable.
if label text is 0 background may red it should change dynamically to shades of the red as the text changes.

Formulate your question right at the beginning in such a way that it does not require unnecessary questions.


I am trying this way but not setting the result.

Make color takes in a list of 3 or 4 numbers. These numbers in this list represent values in an RGB code and can accept values for Red,Green,Blue from 0 to 255 so you can not use decimal. See Colors RGB and also read MIT App Inventor Color Blocks


You are changing the third value of the list, but the R in RGB is at the first value.
Also, only integers are allowed, no decimal places.


will set a random colour from the 16.7 million colours available (apart from transparent: 16777215)