1 Reply Latest reply on Sep 24, 2009 10:39 AM by paul.williams

    Problems  with Flex

    okwu

      Please  could  someone   tell me what  is it I am doing wrong.   have  been trying to display jsp data in a  Flex  datagrid.  I have  not been successful.  My code is  submitted below:

       

      Thank You

      Jonas

       

      My Flex   Code

      ============================================================

       

      <?xml version="1.0" encoding="utf-8"?>
      <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
          applicationComplete="employeeService.send()" viewSourceURL="srcview/index.html">
      <mx:HTTPService id="employeeService" useProxy="false"  resultFormat="e4x" method="POST"
        url="http://10.60.7.49:8084/myTest/workers.jsp" />
       
                   <mx:DataGrid  width="657" height="345"  dataProvider="{employeeService.lastResult.people.person}" x="64" y="96">
                               <mx:columns>
                      <mx:DataGridColumn dataField="name"   headerText="Name"/>
                      <mx:DataGridColumn dataField="age"    headerText="Age"/>
                      <mx:DataGridColumn dataField="skills"  headerText="Skills"/>
                    </mx:columns>
                  </mx:DataGrid>
      </mx:Application>

       

      my  Jsp  Code:

      =========================

      <%
      out.println("<?xml version=\"1.0\"  encoding=\"UTF-8\"?><people><person><name>jonas okwara</name><age>43</age><skills>Java, C++ </skills></person<person><name>chioma okwara</name><age>35</age><skills>bible, linux</skills></person></people>");
      %>