function beginEdit(dg, index)
{
dg.datagrid('selectRow', index).datagrid('beginEdit', index);
setEditIndex(dg, index);
dg.datagrid('changeState', 'editing');
var ed = dg.datagrid('getEditor', { index: index, field: 'CompanyName' });
$(ed.target, "#dataGridMaster").next().find('.refval-text').click(function () {
$(ed.target, "#dataGridMaster").next().find('.refval-text').bind('blur', function () {
alert('test');
});
})
};
//直接放在<script>下就可以,需自行替換FieldName和DataGrid的名字