1 Reply Latest reply on Aug 2, 2008 7:26 AM by Michael Borbor

    Specify dataField value in DataGridColumn

    wiser4me97
      can someone help me and maybe explain how to specify a dataField value in a DataGridColumn. My dataProvider was retrieve from a RemoteObject method which return the result of the query (not formatted to xml).
      the result data is something like this (date,title,details):
      ex.
      Thu Jul 31 00:00:00 GMT+0800 2008, New User!, Some user description and details,
      Thu Jul 31 00:00:00 GMT+0800 2008, New Task!, Some task description,
      Thu Jul 31 00:00:00 GMT+0800 2008, New Alerts!, Alert message


      the thing is, if i just do this line it works:
      <mx:DataGrid id="entries" width="100%" height="400" dataProvider="{myRemoteObject.getWhatsNewList.lastResult}">
      </mx:DataGrid>

      but when i try to control the columns it displays:
      <mx:DataGrid id="entries" width="100%" height="400" dataProvider="{myRemoteObject.getWhatsNewList.lastResult}">
      <mx:columns>
      <mx:DataGridColumn dataField="wnDate" width="100" headerText="Date"/>
      <mx:DataGridColumn dataField="details" headerText="details"/>
      </mx:columns>
      </mx:DataGrid>