# Problem with Variables and Hex colors

**URL:** <https://forum.kirupa.com/t/problem-with-variables-and-hex-colors/205467>\
**Category:** flash\
**Created:** [October 30, 2006, 12:54am UTC](https://forum.kirupa.com/t/problem-with-variables-and-hex-colors/205467 "2006-10-30T00:54:18Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![irok](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/irok/32/2660_2.png) [@irok](https://forum.kirupa.com/u/irok)\
**Post date:** [October 30, 2006, 12:54am UTC](https://forum.kirupa.com/t/problem-with-variables-and-hex-colors/205467/1 "2006-10-30T00:54:18Z")

</div>

Hello,

I’m loading a color from a XML file. eg \*\*0x0AAFD  
\*\*and storing it on a variable. eg \*\*var storecolor = myxml.childNodes[0].attributes.color;

\*\*storecolor returns the value **0x0AAFD**.

If I do,  
box.colorTo( **0x0AAFD** , 0.3);  
it will work.

Where I am having trouble is when I try to use the var in a MCTWEEN function. eg. box.colorTo( **storecolor** , 0.3);

I’ve tried making a the variable a string and a number but still doesnt work.  
Please not that the the variable is a global var.

Any help is appreciated. Thank You  
irok
