ActionScript 2.0 :: LoadVars - Get The Data With The While Loop?

Sep 13, 2006

I'm loading data from sql, by using asp.net. I've made the script in vb, but now i have problems with flash. I can load data, by using Code: trace(this.body); But i dont't know how to get the data with the while loop

[Code]...

View 4 Replies


Similar Posts:


Data Integration :: Using LoadVars With XML Data

Aug 17, 2006

All the examples in the text books, etc. show the LoadVars object being used with a .txt file. Can I use it with a .xml file or not? I have tried but the output panel just shows rubbish data!

View 1 Replies

IDE :: Extracting Data From LoadVars?

Jul 11, 2010

I am using the loadVars class (Flash 8) to load key/value pairs from a mySQL database through php (example &pic1=pic1.jpg&pic2=pic2.jpg&...).

The ultimate goal is to create a dynamic slideshow with a variable length, depending on how many pics were submitted by the user. Since the associative array object returned by loadVars does not share the "length" property of indexed arrays, my guess is that the values need to be converted into a new indexed array before being able to use them in the slideshow.

View 2 Replies

ActionScript 2.0 :: External Data From TXT With LoadVars()

Jul 16, 2011

I'm messing around with trying to load variables from a text file and it's just not working as I'd expect. First, my text file is formatted like this

[Code]...

For example, if I do something like create a simple Dynamic Text Box on the same frame as the above code, to show the value from _level0.Test.variable1, it displays "undefined" even though the debugger indicates this variable has the value "value1" as I wish it to. (using "trace(_level0.Test.variable1)" yields no better results)

I have attemped using onLoad and onData alongside the above code, and neither one has made the situation better. I have also attempted trying to reference the variable in a few different ways, and it's just returning the same thing every time. When I was experimenting last night, I managed to get the variables to show up properly on a "trace()" but not when referenced by other things in the flash file. Regrettably, I cannot remember how I did this. Either way it didn't quite work still. Do I need to do something else to be able to reference loaded data in my project, or is there some fundamental mistake I am making? I'm usng Flash CS3 Pro, if that makes any difference. Flash Player is up to date, etc.

View 0 Replies

ActionScript 2.0 :: Getting Data With Loadvars And Put It In Array

Feb 20, 2004

I want to write out some names from a DB and then get it with loadvars and then put it in an array for easy using later, how do I do this the best way? First thing first I have made an ASP file like this:
Code:
<%
Dim objConnect, objRS, SQL, strConn, i
Set objConnect= Server.CreateObject("ADODB.Connection")
Set objRS= Server.CreateObject("ADODB.Recordset")
[Code] ....
How do I loop out this thing and put it all in an array =?

View 8 Replies

ActionScript 2.0 :: FMX - Can't Get LoadVars For Saving Data

Feb 10, 2005

I'm using Flash MX (2002) and I need to get my variable values saved to a server each time my test subjects run and finish my swf/fla (PHP scripts and a .txt file on the server are being worked on, but that's a different nightmare!). I'm pretty sure I should use LoadVars, NOT SharedObject for this data capture right?. The data must not be overwritten each time over the course of a few months of data collection. The 3 variables are: username (name of the user), counter (this keeps track of which version the user chooses from the start menu), numcorrect (keeps track of the number of times the <right> arrow key is pressed).

2 main problems: I don't know where to put in the LoadVars obj (in the AS code of "finaldisplay" frame?) AND I don't know how to build/format the LoadVars object to capture the data in the 3 variables I listed above. I've got several Flash books and have done online tutorials, so for something so simple (3 lousy variables!)...why is my life so miserable? Here's my zipped .fla.

View 2 Replies

Data Integration :: LoadVars - SendAndLoad() Over Https?

Feb 20, 2007

I am having problems with loadVars over https. What I am trying to do is sending credit card information from a flash store to a PHP-script on a server over https, and the PHP-script should return a reply. (So I am using the LoadVars sendAndLoad command). The problem is that the reply I get from the script is empty. If I try the same over http, it works fine.

View 4 Replies

ActionScript 2.0 :: Loadvars Asp - Read Data - Write Value?

Oct 7, 2011

I want to make, read data from asp. How can I write this value?.

[Code]...

View 0 Replies

ActionScript 2.0 :: Can't Get Head Around LoadVars For Saving Data

Feb 10, 2005

I'm using Flash MX (2002) and I need to get my variable values saved to a server each time my test subjects run and finish my swf/fla (PHP scripts and a .txt file on the server are being worked on, but that's a different nightmare!). I'm pretty sure I should use LoadVars, NOT SharedObject for this data capture right?. The data must not be overwritten each time over the course of a few months of data collection.

The 3 variables are: username (name of the user), counter (this keeps track of which version the user chooses from the start menu), numcorrect (keeps track of the number of times the <right> arrow key is pressed).

I don't know where to put in the LoadVars obj (in the AS code of "finaldisplay" frame?) AND I don't know how to build/format the LoadVars object to capture the data in the 3 variables I listed above.

View 2 Replies

ActionScript 2.0 :: Limits On Sending Data With LoadVars?

Feb 21, 2008

I was wondering if anyone had found out that there is a limit to how much information can be sent with LoadVars. I guess that limit could be the number of properties of the loadVars object, or size of the properties being sent.

View 2 Replies

ActionScript 2.0 :: Sending Large Data With Loadvars?

Mar 20, 2009

I've got a small problem with loadvars. I want to send data from Flash to PHP, which usually works well. But right now I need to send "larger" amounts of data around 10-20kb and loadvars doesn't work anymore.

Using loadvars to open browser-windows seems to work fine, but I want everything to happen inside of flash.

The code is:

Code:
datastring = "1, 2, 3 (...) 4998, 4999, 5000"; // long text
loadstring = 'save.php?data='+datastring;
db = new LoadVars();

[Code].....

Works fine with small text, with big text nothing happens. How to do this the right way?

Edit: Loadvars seems to work up until 4050 characters, 4051 and it doesn't send anymore. But I can't really split the query..

View 1 Replies

Data Integration :: Adding Variables To LoadVars Object?

Apr 27, 2007

I have an application that reads a PHP script and populates the Flash applets using the following on frame 1:

[Code]...

A combobox (created with the returned data) is created on frame 61. When a selection is chosen in the combobox I need to add the value returned from the combobox to the variable catvar, add this variable to the LoadVars object and run the script again. It seems to set c.catvar initially but when I use the 'sendAndLoad command the second time c.catvar isn't included. Is it possible to add variables to a LoadVars object created
on frame 1 from frame 61?

View 1 Replies

Data Integration :: Loadvars Blocked When Run From Powerpoint 2003?

Sep 8, 2006

I have done many assignments where I have developed Flash movies that access external databases over a web pages and present the results in custom made graphs. Perfect for scorecard applications etc. The main benefit of using Flash has been that the whole thing can be embedded and run from PowerPoint,

[Code]...

View 1 Replies

Flash - LoadVars Doesn't Wait Until Data Is Loaded

Jun 8, 2009

variable = 0;
function change() {
variable = 1;
}

[code]....

The problem is that it executes #Second before #First, which means that the object is not fullly loaded but the code continues nonetheless. Is there a way handle this? I have tried using a while loop, but this is ugly and makes flash crash. Is there any decent way to handle this, does it have to do with better code structure/program flow or is there a technical way to make it wait? Also note: This code is executed on the server side, which means there are no frames involved.

UPDATE:When projects get bigger, this gets very ugly, especially when you are retrieving mulitple things from a server, you have to use very deep nesting, you have to keep repeating the same code, example for buying a serial:

a.onload() {
if(moneyAmount > 10){
b.onload(pay) {

[code]....

View 1 Replies

Data Integration :: LoadVars-using Send To Pass A Variable From Flash To Php

Mar 24, 2008

For the life of me, I've tried everything: I've researched LoadVars on Adobe forum, used David Powers' books, googled 'flash to php', LoadVars, etc. and tried sendAndLoad, send, and using $_POST, $_GET, $_REQUEST. $HTTP_POSTVARS but I keep getting this same error.

I have a Unix server running Apache/PHP 4 - LoadVars worked to load name-value pairs into an array -see thread)

My goal with this simple app is to prototype being able to pass a variable from flash to a variable in php.

Parse error: syntax error, unexpected T_VARIABLE in flash_to_SQL.php on line 5

Actionscript 2.0 code:

var c :LoadVars = new LoadVars();
c.testing = "123FOUR";
c.send ("

[Code]....

View 3 Replies

Media Server :: Using LoadVars In SSAS To Send Data To A Php File?

Mar 21, 2012

I am using FMS 4.5 and have a simple application which I want to use to send two strings to a php file. But I get a compilation error whenever I try to assign any value to these objects:
 
Here is main.asc:
 
<code>
var variables = new LoadVars();
variables.username = "uname";
variables.send(http://url.abc.com/test.php,POST)
</code>
  
I can't compile with the second line. FMS just says: Sending error message: Compilation error
 
How do I send variables to a HTTP URL?

View 2 Replies

IE Not Recognizing Post Data Using LoadVars From Flash Inside A Frameset?

Sep 16, 2010

This code is being run from a frameset in IE8. When the new window is opened, the form data is not being recognized. It appears that the http header, "content-type: application/x-www-form-urlencoded", is not being passed into IE and this is causing the post data not to be processed. The data is there, IE is just doing nothing with it.

This code works fine in FF and Chrome, and in fact the correct headers are passed in FF and Chrome.

NOTE: The new page is on a different site, but i don't know why that would cause a problem with a POST and not a GET.

Flash code:

varSender = new LoadVars();
varSender.title = _parent.tCourseTitle;
varSender.notes = input_txt.text;
varSender.send("http://example.com/notes/print.cfm", "_blank", "POST");

I have tried adding the header to the send request, but that has no effect at all. The contenttype header is still missing and it still works everywhere but IE.

My current work around is to use a GET instead of a post, but that's ugly and it limits us in the size of data we can pass but for now at least it works.

View 1 Replies

IDE :: LoadVars - Send Data From PHP To Flash - Does Not Display The Contents In The Variable

Jun 23, 2009

I would like to send data from PHP to Flash however, it sends just fine but when displaying on Flash, it does not display the contents in the variable. Instead, it displays the name of the variable. This may be a simple answer but I'm quite new to this. Here is the code in Flash.

[Code]...

View 7 Replies

ActionScript 2.0 :: TUTORIAL Error - Change LoadVars() Into LoadVars()?

Apr 13, 2004

One of the moderators, could you've a look at this tutorial: [URL] it doesn't works with me, maybe because I've 2004 so if you change loadVars() into LoadVars() it should work

View 2 Replies

Data Integration :: Firefox 2.x Sending Variables To PHP Scripts With The LoadVars.send / POST Method

Dec 29, 2006

There seems to be a problem with Firefox 2.x sending variables to PHP scripts with the LoadVars.send/POST method.

<br>

The same problem doesn't occur in IE or Opera. <br>See this url for example to try in both FF and IE/Opera: here. <br>The source files are here g.zelenka@iinet.net.au

View 4 Replies

ActionScript 2.0 :: Using LoadVars.getBytesLoaded And LoadVars.getBytesTotal?

Sep 1, 2003

Whenever i try to display anything returned by LoadVars.getBytesLoaded or Load....Total, it gives me NaN.

View 14 Replies

ActionScript 1/2 :: "POST" JSON Data In The Body Of A Request With LoadVars?

Mar 10, 2009

Is it possible to "POST" JSON data in the body of a request with LoadVars? I understand LoadVars sends data as name>value pairs. How can I send the data in the body instead?

View 1 Replies

Data Integration :: XML Nested Loop?

Nov 30, 2006

just completed a little test for making a treecomponent with custom icons / bransch.However, i can only get my first branch to show customicons.(links - document) I figure I need to make a nested loop to Iterateover nextSibling?. I tried ALOT, but i guess Im doingsomething completely rong.here is code for my tree so far:

my_xml = new XML();
my_xml.ignoreWhite = true;
my_xml.load("tree.xml");

[code].....

View 1 Replies

ActionScript 3.0 :: Store Data With For Loop?

Aug 16, 2010

I want to display 0 to 1200 with y Axis.

ActionScript Code:
private var Yaxis:Number = new Number();
for (var i:Number=0; i<Yaxis; i++);

[Code].....

View 9 Replies

ActionScript 2.0 :: For Loop For Loading External Data?

Jul 28, 2009

I have a bit of a problem finding the correct syntax. I have a whole lot text variables here. The myLV value is in a external text file. So myLV.nr1 from my external textfield is loaded in ovrnr1.text. This way I can easily change the value in my text document.

ovnr1.text = myLV.nr1;
ovnr2.text = myLV.nr2;
ovnr3.text = myLV.nr3;
ovnr4.text = myLV.nr4;

If I put it like this it works fine but I thought, hey, in stead of writing
150 of these I can put it in a for loop. So I tried this.

for (i=1; i<150; i++) {
ovnr[i].text = myLV.nr[i];
}

However, this does not seem to work ? And could I do it to a button too ? So instead of writing 150 button onrollovers I could also make a loop for it ?

Something like
for (i=1; i<150; i++) {
this.btn[i].onRollOver = function() {

[Code]....

View 2 Replies

ActionScript 3.0 :: Add Data To An Array From Textinput Through Loop?

Jun 9, 2010

I am trying to add data to an array from the textinput which i have created through for loop, but not working[code]...

View 2 Replies

ActionScript 2.0 :: Save These Data And Changing With For Loop?

Jan 12, 2010

i was trying to save these data and changing with for loop

povDisp1 = mySO.data.cas1;
povDisp2 = mySO.data.cas2;
povDisp3 = mySO.data.cas3;
povDisp4 = mySO.data.cas4;
povDisp5 = mySO.data.cas5;

[code]....

problem is that it is showing only my last variable ( i don't know what is problem in for loop)i've solved it with these

//thanks
for (var n:Number = 0; n < 51; n++)
{
mySO.data["cas" + n] = this["povDisp" + n];
}

View 3 Replies

ActionScript 2.0 :: Get The Data From An XML And Store It During The For Loop Into An Array?

Mar 2, 2004

I'm having a problem with for loops and the arrays that were created while those loops. I mostly get the data from an XML and store it during the for loop into an array, am I obligated to use the array imediatley? cause if I want to use some of it, it's all dissapeared.I used this for loop in an onLoad function because I'm used to load the XML data like this...

View 12 Replies

ActionScript 3.0 :: Loop Through XML Data With A Pause - Fadein And FadeOut?

Jul 21, 2011

I have an XML file that is updated every three minutes. The amount of records in the file can and will change. What I want is to load the XML, fade in 6 records, pause 5 seconds, fade out then in the next 6 records until the end of the file is reached. At that point, reload the XML file and repeat the process till infinity.

I have the XML file loading. I am able to count the records, parse the XML, and manually place XML data into dynamic text fields. I cannot get my FOR loop to function properly or get the script to pause between pages. I have not even attempted the fade in/out yet. I think I should have it parsing data properly before I add the cosmetics.

MY CODE:I do not get any compiler errors, but I do get an ouput error:

TypeError: Error #1010: A term is undefined and has no properties.
at xml_data_fla::MainTimeline/processXML()
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at flash.net::URLLoader/onComplete()

I think it is throwing this error as soon as it tries to display an empty record, if that makes since. Say there are 17 records. 17 / 6 = 2 with 5 remaining. When it tries to display the 3rd incomplete page the error is thrown (I think). When I test the file, it only displays the last page before an incomplete page. Here is what I have so far:

ActionScript Code:
//  ***  XML LOADER  ***  //
var xmlLoader:URLLoader = new URLLoader();
var xml:XML;

[code]....

View 2 Replies

ActionScript 2.0 :: Creating Loop To Pull Data From XML And Load Into SWF

Mar 25, 2005

I am currently scripting a Flash application at work which will pull data from an xml file (.jpg's and text) into template swf's created by our designers, for use in online product commercials, realty/property tours, etc. I am creating a loop which will pull data from the xml and load them with createEmptyMovieClip(). Here's the code:

Code:
_root.dynLoad = function() {
trace( "initializing dynLoad function..." );
for( _root.g = 1; _root.g <= _root.featLength; _root.g++ ) {
if( _root.g == 1 ) {
this.createEmptyMovieClip( "dynPic", this.getNextHighestDepth() );
[Code] .....

I am not the heaviest with actionscript and I can get the first two pictures to load, but after that the pics get loaded into the duplicated clip. I tried my hardest to get the else block to dynamically increment the "dynPicNew" ( ex. load it into "dynPicNew" + _root.g ), but I can't nail it! How can I get the duplicateMovieClip() to increment the load target dynamically?

View 4 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved