Hello,
I have always been frustrated by the LoadVars method in Flash. I am simply trying to hit a submit button which calls a function w/ the LoadVars method to read the contents of 10 text files. If the proper contents in the text files are found, then the program will proceed to the next frame.
If I could set a return variable in a function such as this:
_global.file_found;
function file_exist( file_name )
{
fileExists = new LoadVars();
fileExists._parent = this;
fileExists.onLoad = function(success)
{
if(success)
{
trace( "FILE EXISTS!!!" );
file_found = true;
}
else
{
file_found = false;
trace( "FILE DOESN'T EXIST**" );
}
}
fileExists.load( 'patient_sessions/' + file_name + '.txt' ) //initiate the test
return file_found;
}//__endFunc__
It would probably solve all my problems. I can't seem to make a global variable to read out side the
I have always been frustrated by the LoadVars method in Flash. I am simply trying to hit a submit button which calls a function w/ the LoadVars method to read the contents of 10 text files. If the proper contents in the text files are found, then the program will proceed to the next frame.
If I could set a return variable in a function such as this:
_global.file_found;
function file_exist( file_name )
{
fileExists = new LoadVars();
fileExists._parent = this;
fileExists.onLoad = function(success)
{
if(success)
{
trace( "FILE EXISTS!!!" );
file_found = true;
}
else
{
file_found = false;
trace( "FILE DOESN'T EXIST**" );
}
}
fileExists.load( 'patient_sessions/' + file_name + '.txt' ) //initiate the test
return file_found;
}//__endFunc__
It would probably solve all my problems. I can't seem to make a global variable to read out side the