1 Reply Latest reply on Jul 22, 2013 7:57 AM by Flex harUI

    FLEX 3 : error 1009 impossible to access object reference null

    yosrabaccar

      I have the following code. and the method getFinancement throws error 1009. By the way rofin is used to make RPC remote procedure call. Financement is an actionscript class with fields codefin and fpfin that has a table in mysql with fields codefin and fpfin. What I want to do is to acess financement table to access codefin and fpfin values from the database. Sorry for the code is not put into the right sections of code. I have only put the lines that throw the error 1009. I work on Eclipse EUROPA, tomcat apache 6 as web server and mysql for storing database and BlazeDS. Any help would be appreciated Thanks

       

       

       

       

      <mx:TextInput id="codeec" x="99" y="43" width="205"/>

        
      <mx:RemoteObject id="rofin"
      destination="Financement"
      endpoint="http://localhost:8080/Credit/messagebroker/amf" />


      private function findCredit(event:MouseEvent) : void
        {
             rofin.findFinancement(codeec.text);
             rofin.addEventListener(ResultEvent.RESULT, getFinancement);
         }
        private function getFinancement(result: ResultEvent): void
      {
          var f2: Object = new Object();

          f2 = result.result;

          codefin.text = f2.codefin;
          fpfin.text = f2.fpropre;
          rofin.removeEventListener(ResultEvent.RESULT,getFinancement);
      }