ok, i have the javascript for the AfterRowActivate event. I am getting an error on my page
Error: Object doesn't support this property or method
Code: 0
here is the script
function EnableDisableButtons() { var grid = document.igtbl_getGridByID("ctl00_ContentPlaceHolder1_uwg_Schedule") var type = grid.Rows[grid.ActiveRow.Index].Cells[15].Text if (type != 'APPT') { document.getElementById('ctl00_ContentPlaceHolder1_ddlResults').disabled = true; document.getElementById('ctl00_ContentPlaceHolder1_btnSaveResult').disabled = true; document.getElementById('ctl00_ContentPlaceHolder1_btnContact').disabled = true; } else if (type = 'APPT') { document.getElementById('ctl00_ContentPlaceHolder1_ddlResults').disabled = false; document.getElementById('ctl00_ContentPlaceHolder1_btnSaveResult').disabled = false; document.getElementById('ctl00_ContentPlaceHolder1_btnContact').disabled = false; }
any ideas? I htink it is something simple, but i don't see it.
the answer was i wasn't passing anything into the js as required, i will paste everything back in...
function EnableDisableButtons() should have been
function EnableDisableButtons(tablename, itemname)
var grid = igtbl_getGridById(tablename); var row = igtbl_getRowById(itemname); var cell = row.getCell(15).getValue(); if (cell != 'APPT') { document.getElementById('ctl00_ContentPlaceHolder1_ddlResults').disabled = true; document.getElementById('ctl00_ContentPlaceHolder1_btnSaveResult').disabled = true; document.getElementById('ctl00_ContentPlaceHolder1_btnContact').disabled = true; } else if (cell = 'APPT') { document.getElementById('ctl00_ContentPlaceHolder1_ddlResults').disabled = false; document.getElementById('ctl00_ContentPlaceHolder1_btnSaveResult').disabled = false; document.getElementById('ctl00_ContentPlaceHolder1_btnContact').disabled = false; } }