ExternalInterface.call("function()" +
"{" +
"window.location.href='http://localhost:8080/flexDemo/flex_users.html?username="+txtusername.text+"';" +
"}" +
"");
"{" +
"window.location.href='http://localhost:8080/flexDemo/flex_users.html?username="+txtusername.text+"';" +
"}" +
"");
改为
window.location.href='http://localhost:8080/flexDemo/flex_users.swf?username=传递给swf文件而不是html文件就可以了!