0 Replies Latest reply on Jul 11, 2007 11:19 PM by Thenmalar

    How to bind XMLList with Webservices

    Thenmalar
      Hi to all,
      I'm new to Flex. I want to pass multiple records to my SAP backend through Webservices, for that i have stored my records inside my XMLList then i try to pass this XMLList to educational Tag which resides inside my webserices
      when i pass XMLList, only one entry is been updated. but my XML List having multiple entries. how do i make it work????

      [Bindable] public var x1:XMLList=new XMLList();
      public function ADDEDU():void{

      flag=flag+1;

      Alert.show("Flag"+flag);

      for(var j:int=0;j<1;j++)
      {
      //x=new XML();
      //Alert.show("Education XML"+x.toString());

      var x:XML =new XML(<item>
      <FromDate>{EduFD.text}</FromDate>
      <ToDate>{EduTD.text}</ToDate>
      <EducEst>51</EducEst>
      <EducTra>{Specialno}</EducTra>
      <Institute>{EduTA.text}</Institute>
      <Cntry></Cntry>
      <Certific></Certific>
      <BrStudy1></BrStudy1>
      <BrStudy2></BrStudy2>
      <Mark>{int(MarkTxt.text)}</Mark>
      </item>);
      Alert.show("Education XML"+x.toString());
      //x1+=x;

      }
      //x1=<item></item>;

      x1=x1+x;

      //x2=new XML(x1);
      Alert.show("Education XML X1"+x1.toString());
      }

      this fun will call when ADD Record button clicks, & finally WES3.ZhrFunApplicantCreate.send(); is used this to send the data ...
      <mx:WebService id="WES3" destination="applicantws" useProxy="true" fault="Alert.show(event.fault.faultString) , 'Error'" >
      <mx:operation name="ZhrFunApplicantCreate" result="onResult2(event)" resultFormat="e4x" >
      <mx:request>
      <Education>
      { x2 }
      </Education>.................

      i don't know how to pass XMLList to webserice can anyone please bring me the solution ???????????

      thanks in advance.
      Regards,
      Thenmalar