View Full Version : set focus in last row
stonyx
08-23-2006, 12:34 AM
any one know how to set focus always on the last row of my grid?
Flash Gordon
08-23-2006, 03:33 AM
Hi
Could you be more vague? :p
Maybe Selection.setFocus(lastrow);
stonyx
08-23-2006, 09:47 PM
i think your right this is some of the code of my project i have two question hope you can help
how to dalete the first item of datagrid2 after 5 items added to it and to always set focus on the new item added so i can delete it one by one to
thasnks :0)
[Bindable]
private var _xlcdatagrid:XMLListCollection;
[Bindable]
private var _xlcdatagrid2:XMLListCollection = new XMLListCollection;
private function onResult(oEvent:ResultEvent):void
{
_xlcdatagrid = new XMLListCollection(oEvent.result.name)
datagrid.dataProvider = _xlcdatagrid;
}
private function selectItem():void
{
_xlcdatagrid2.addItem(datagrid.selectedItem);
}
function deleteRow():void {
if (datagrid2.selectedIndex!=undefined) {
_xlcdatagrid2.removeItemAt(datagrid2.selectedIndex );
}
}
public function removeAll():void
{
var len:int = length;
if (len > 0)
{
_xlcdatagrid2.removeAll()(datagrid2);
}
}
|
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.