Focus can be a real pain, as we all know.  

I have a function which re-focuses a datagrid so:

private function staffGridFocus():void
{
    salesStaffGrid.setFocus();
    salesStaffGrid.selectedIndex = gridSelectLine;
    editStaffCell = {columnIndex:0, rowIndex: gridSelectLine};
    salesStaffGrid.editedItemPosition = editStaffCell;
}

no arguements are expected or required.

After my user saves data to MS SQL 2005, via Janus, I alert them that
the action has been completed with:

Alert.show("Staff data updated", 'Information:', 0, this,
staffGridFocus, informationIcon);

However, I get a runtime error:

ArgumentError: Error #1063: Argument count mismatch on
main/main::staffGridFocus(). Expected 0, got 1.

I'm  *guessing* that the Alert windows's closeEvent is being passed as
an arguement to the function for some reason.

How can I prevent this, or have you guys any other ideas please?

Reply via email to