I have a problem which I thought I had solved but it isn't working. Have been working on it for the last two days now. I am passing variables into flash from a cgi script. I have been using dynamic text fields to see if the variables are passing into the game. These text fields show the right information so I know that the variables are being passed. The problem is that I cannot seem to get the data to save into another variable after I convert it to a number. Here is my code:
Frame1:
_focusrect = 0;
fscommand ("allowscale", "false");
// -----------------------------------------
id = "";
fLoadDone = 0;
address = "
http://www.blahblah.com/blah.cgi";
// -------------------
loadVariablesNum ("
http://www.blahblah.com/blah.cgi?rand="+random(1000), 0);
Frame 2:
play();
Frame 3:
if (!fLoadDone) {
gotoAndPlay (_currentframe-1);
}
Frame4:
//........previousstuff
_root.backGround.myPoint = Number(mypoint);
//mypoint is one of the variables being passed into flash from the database.
//.....more stuff
This is just the part that is not working
the dynamic text field named mypoint works perfectly.
mypoint has a value of 1000 when it is sent in (1000 as a string of course).
Number(mypoint); keeps giving me a value of 0.
If you have any ideas as to what I am doing wrong or need some more information to help me figure this out please let me know I would really appreciate it.
At this point I feel like I am banging my head against a brick wall
Thank you.
Widha