Converting decimal to int

Hi all, I'm quite new to MIT inventor so sorry if I'm not conforming to the rules.
Here is my problem
I've got a slider (called redslider) which has a min value of 0 and max of 255
I have a global variable called globalRED which is set to the value of the slider, but the value is decimal and I need it to be integer.
So I have done the following

whenslider position changed
set globalRED to redslider thumbposition
set gloabalRED to floor
Then I set a label to show me the value of globalRED

globalRED always ends up at 1 ( ie 166.7 becomes 1)
I know it starts off at 166.7 because if I remove set gloabalRED to floor
it's the original value of redslider.

Note I have also tried round instead of floor.

Any help very much appreciated.

Hello dazz700

You will need to have a 2nd variable to hold the integer because globalRED is tied to the slider thumb position.

Hi thanks, I realised after I posted that I could set globalRED round to somthing else and found that
set globalRED to round and placed get globalRED worked.

Basically set globalRED to globalRED round