fixed bug in datagrid