Define a variate to indicate if to select a row.
$('#dg').datagrid({
rowSelectable: true,
onBeforeSelect: function(){
var opts = $(this).datagrid('options');
return opts.rowSelectable;
}
})
After selecting a row, turn off this variate.
$('#dg').datagrid('selectRow',1)
$('#dg').datagrid('options').rowSelectable = false;