• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Getting data from actionscript class file into Datagrid

 
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I have problem printing the values from an actionscript class. The following is my actionscript class :

package com.script.vo
{
[RemoteClass(alias="com.java.classes.vo.AdminClassVO")]
[Bindable]

public class AdminClassVO
{
public function AdminClassVO()
{
}

public var fromStation:StationVO;

public var toStation:StationVO;

public var busNumber:BusMasterVO;
}
}

The corresponding mxml code is :

<mx:DataGrid width="70%" height="95%" paddingLeft="40" dataProvider="{flightSectors}"
styleName="gridStyle" id="sectorsDataGrid">
<mx:columns>
<mx:DataGridColumn id="from" dataField="fromStation" width="150" headerText="From"/>
<mx:DataGridColumn id="to" dataField="toStation" width="150" headerText="To"/>
</mx:columns>
</mx:DataGrid>
I have written another method to fill the data into the arrayCollection variable flightSectors. The text that is displayed in the datagrid is like Object <AdminClassVO>. The actual value is not displayed.
Please help me...!
 
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Nitin Menon wrote:Hi,


public var fromStation:StationVO;

public var toStation:StationVO;


<mx:DataGridColumn id="from" dataField="fromStation" width="150" headerText="From"/>
<mx:DataGridColumn id="to" dataField="toStation" width="150" headerText="To"/>
</mx:columns>
</mx:DataGrid>




you are assigning an object to dataField property directly? I think you should try with object name like toStation.somefield ??
 
Nitin Menon
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank you very much. I got the solution.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic