Welcome, Guest. Please login or register.
Did you miss your activation email?
05/23/12, 00:45
Home Help Search Login Register
News: Parsley Flex framework review featuring quiz application, in our Flex frameworks series
Flex SDK 4.5 mobile roadmap: begin with your mobile development
Swiz Flex framework review featuring quiz application
New homepage we release our new Homepage, take a look ...

+  Flash-db
|-+  Server side Scripting and Database Support
| |-+  MySQL, PostgreSQL, MS SQL, Access (Moderators: Flash-db, Musicman, Ronald Wernecke, Jorge Solis, Andries Seutens)
| | |-+  Utilizing data from database
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Print
Author Topic: Utilizing data from database  (Read 2158 times)
Widhadh Waheed
Server what's that
*
Posts: 1



View Profile Email
« on: 04/04/02, 22:45 »

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
Logged
flashswami
Jr. Programmer
**
Posts: 55


vene vidi vector


View Profile WWW
« Reply #1 on: 04/05/02, 04:53 »

Have you checked the debugger Widhadh? It may offer you a bit more of a clue as to whats going on?
Logged

Pages: [1] Print 
« previous next »
Jump to:  


Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!
anything