my scroll stays at the previous position on refreshing data or bring in new data to the dataprovider but throws an error when i try to scroll to the top and also has lots of blank rows of data. is this some sort of bug?
 
public var listScrollPosition:Number = 0;
 
public function rememberDGPosition(){
   listScrollPosition = devicesListViewGrid.verticalScrollPosition;
   }
  
 public function loaded(){
       gateway.call( "DBDeviceManager.getPage5", new Responder(onResult, onFault),userid);
   }
   public function onResult(result:Array):void{
       abcd = result;
      devicesListViewGrid.verticalScrollPosition = listScrollPosition ;
       intervalIdList = setInterval(loaded, durationList);
   }
++++++++++++++++++++++++++++
<mx:DataGrid x="10" y="3" verticalGridLines="false" useRollOver="false" id="devicesListViewGrid" dataProvider="{abcd}" width="704" height="392" mouseDownEffect="none" selectionColor="#CDF3DD" rollOverColor="#013826" alternatingItemColors="[#FFFFFF,#E1F5E8]" headerColors="[#006E4F,#006E4F]" borderStyle="solid" horizontalGridLineColor="#BAE2CA" verticalGridLineColor="#BAE2CA" horizontalGridLines="true"  borderColor="#BAE2CA" color="#FFFFFF" sortableColumns="false"
render="rememberDGPosition()" >
 
     <mx:columns>
     <mx:DataGridColumn width="50" id="datagridcolumn" headerText=" "  itemRenderer="CheckCellRenderer"/>
     <mx:DataGridColumn headerText="NAME" dataField="name" itemRenderer="CheckBoxRenderer"/>
     
      <mx:DataGridColumn width="140" headerText="CURRENT STATUS" dataField="pmid" itemRenderer="chartPivot"/>
    
      <mx:DataGridColumn editable="false" width="90"  headerText="DURATION" dataField="duration" itemRenderer="DurationRenderer"/>
      <mx:DataGridColumn editable="false" width="110" headerText="LAST CHANGE" dataField="lastchange" itemRenderer="lasChangeRenderer"/>
      <mx:DataGridColumn  editable="false" width="100" headerText="PREVIOUS STATUS" dataField="previousstatus" itemRenderer="previousStateRenderer"/>
      <mx:DataGridColumn editable="false" headerText="GROUP" dataField="group" itemRenderer="groupRenderer"/>
      
      
     </mx:columns>
    </mx:DataGrid>
 
Thanks,
Chaitu.
__._,_.___

--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com





SPONSORED LINKS
Web site design development Computer software development Software design and development
Macromedia flex Software development best practice


YAHOO! GROUPS LINKS




__,_._,___

Reply via email to