- Sold between 250 000 and 1 000 000 dollars
- Has been a member for 5-6 years
- Author was Featured
- Item was Featured
- Author had a File in an Envato Bundle
- Author had a Free File of the Month
- Interviewed on the Envato Notes blog
- Referred between 200 and 499 users
Hi,
I want users to be able to select the easing type of a tween via xml. For example “Regular.easeOut”. How can I parse the string to a regular expression so it can be recognised by flash?
Thanks 
eval(“Regular.easeOut”)
- Sold between 250 000 and 1 000 000 dollars
- Has been a member for 5-6 years
- Author was Featured
- Item was Featured
- Author had a File in an Envato Bundle
- Author had a Free File of the Month
- Interviewed on the Envato Notes blog
- Referred between 200 and 499 users
gives me an undefined…
I tried it. It works. Use eval(“text” )
- Sold between 250 000 and 1 000 000 dollars
- Has been a member for 5-6 years
- Author was Featured
- Item was Featured
- Author had a File in an Envato Bundle
- Author had a Free File of the Month
- Interviewed on the Envato Notes blog
- Referred between 200 and 499 users
var easing = eval(XMLdaten_easing[p]);
trace(easing);
= undefined!

var easing = XMLdaten_easing[p]; easing = eval(easing );
Use the code above. You wrote it before giving text value.
- Sold between 250 000 and 1 000 000 dollars
- Has been a member for 5-6 years
- Author was Featured
- Item was Featured
- Author had a File in an Envato Bundle
- Author had a Free File of the Month
- Interviewed on the Envato Notes blog
- Referred between 200 and 499 users
Did exactly as you said… Still not working.
var easing = XMLdaten_easing[p];
easing = eval(easing);
trace(easing);
- Bought between 1 and 9 items
- Exclusive Author
- Has been a member for 5-6 years
- Item was Featured
- Netherlands
- Referred between 10 and 49 users
- Repeatedly Helped protect Envato Marketplaces against copyright violations
- Sold between 10 000 and 50 000 dollars
Have you tried making it a var first and then eval?
var easing = XMLdaten_easing[p];
myEase = eval(easing);
????
You could write an else if statement to construct what you need.
var easing = XMLdaten_easing[p];
Split it at the dot
mySplit = easing.split(”.”);
then check the first part of the mySplit
if(mySplit0==”Regular”){
construct what you need
} else etc
Then check the second. Bit more work involved and my coding could be off, but it’s an option.
Regards, FonZ
Trace parameter can’t be not understand it. Because, your text changes to Easing object. Try it on the tween method. It works so.
