2017-08-24 3 views
-4

これはこれは、エラーが発生し一部であるactionscript 3 "用語は定義されておらず、プロパティもありません。"

TypeError: Error #1010: A term is undefined and has no properties. 
    at p21_fla::MainTimeline/baba()[p21_fla.MainTimeline::frame1:24] 

私のエラーです:

variables.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, loaderIOErrorHandler); 

これは正しいです私の完全なコード

var variables:URLVariables = new URLVariables(); 
variables.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, loaderIOErrorHandler); 
var varSend:URLRequest = new URLRequest("https://gteckids.000webhostapp.com/gteckids/login.php"); 
varSend.method = URLRequestMethod.POST; 
varSend.data = variables; 

function loaderIOErrorHandler(e:Event){ 
trace("Error loading image thumbnail"); 
} 

var varLoader:URLLoader = new URLLoader; 
varLoader.dataFormat = URLLoaderDataFormat.VARIABLES; 
varLoader.addEventListener(Event.COMPLETE, completeHandler) 

variables.Parent_Username = uname_txt.text; 
    variables.ParentPassword = pass_txt.text; 
    variables.sendRequest = "parse";  
    varLoader.load(varSend); 

function completeHandler(event:Event):void 
{ 


var phpVar1 = event.target.data.var1; 

if(phpVar1!="No"){ 
    btn_ok.visible = true ; 
    lis.visible = true; 
parent_id.text = phpVar1; 


} 


else{ 
    btn_okw.visible = true ; 
    lis1.visible = true; 
} 
} 
+1

コードを画像として投稿しないでください。完全なコードをここに貼り付けます。 – poke

答えて

2

で、URLVariablesオブジェクトのインスタンスにはありませんそのようなメンバーがいる場合は、次の仕様を確認してください:Adobe Documentation: URLVariables。スクリーンショットのようにあなたのコードを投稿したことがない、してください

... 
varLoader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, loaderIOErrorHandler); 
... 

をそして次のようにあなたのローダにでIOErrorEventリスナーを追加します 。

+1

申し訳ありませんが、これは初めての質問です。XD –

関連する問題