Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
5
AfterRowInsertHandler triggers postback.
posted

I'm trying to fill some cells in my grid with the current date as a default value on the client after a new row is inserted but the script function triggers the rowupdate.  I'd like to be able to add these values, let the user enter addition information, and then trigger the rowupdate when a new row is enters, which is the behavior without the function below.  Is there something wrong with the function below or a way to postpone the postback until the selected row changes? 

 

function UltraWebGrid1_AfterRowInsertHandler(gridName, rowId, index){

var today_date= new Date();

var month=today_date.getMonth();

var today=today_date.getDate();

var year=today_date.getYear();

var month = month + 1;

var row = igtbl_getRowById(rowId);

row.getCell(1).setValue(month + "/" + today + "/" + year,false);

row.getCell(2).setValue(month + "/" + today + "/" + year,false);

}