看板 Flash 關於我們 聯絡資訊
發現這篇文章 http://0rz.tw/XIueW 以文章中的說法 var cls:Class = getDefinitionByName("mx.controls.Button") as Class; addChild(new cls()); 是可行的(需 import mx.controls.*) 接下來我這樣運用 var cls:Class = getDefinitionByName("mx.containers.Panel") as Class; addChild(new cls()); 結果Debug一直出現未定義變數Panel的Error 已經有 import mx.containers.*; [解法分享] 加上... private var containersArr:Array = [Panel, TitleWindow]; //視需要增加 搞定!!! -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 59.127.110.132 ※ 編輯: mosluce 來自: 59.127.110.132 (09/11 16:14) ※ 編輯: mosluce 來自: 59.127.110.132 (09/11 16:14) ※ 編輯: mosluce 來自: 59.127.110.132 (09/11 16:19)