when i click the button,do "checkUsername()",it check if the 
filled "usename" have been used. I use RemoteObject to pass 
the "username" to java , java return the result :"true"or "false" 
(string Type)
Error is:  Cannot invoke method 'ifUsernameUsed'.

There is code.
/////////////////////
<mx:script>
   ...
   public function checkUsername():void
   {
        ...                                     
        String s=BlogSpaceDatabase.ifUsernameUsed(Trim  
(textInputUsername.text));
        ...                                             
   }
   ...
</mx:script>

<mx:TextInput id="textInputUsername"/>

<mx:Button id="btnCheckUsername" label="¼ì²âÓû§Ãû" 
click="checkUsername()"/>

<mx:RemoteObject id="BlogSpaceDatabase"  destination="BlogSpaceConn" 
showBusyCursor="true" fault="ErrorFunction(event)">
   <mx:method name="ifUsernameUsed" />
</mx:RemoteObject>

Reply via email to