-
I need to evaluate the result of an equation in flash. However, the equation is a string (e.g. "5+6+1-3")
Could anyone know how to do it?
-
try using the string functions, like the slice() function to cut up the string and then convert the strings to numbers. You will need to slice the string four times for the four + - / and *.
It is a bit time consuming but this is what I know.
Check the Flash help to see how the string functions work.
Hope that helps
-
Still not understand
Thanks for your reply!
However, I would like to ask how to convert the +, - , * and / to be operator rather than string?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|