Re: nuBuilder To Do List
Posted: Fri Aug 23, 2013 6:50 am
massiws,
Here is some custom code that can be put on 'Before Browse' to disable clicks (in this case, the first ten rows), but it could be conditionally on any of the rows/column values..
Disabling things this way means you only run it on rows of the current page.
Steven
Here is some custom code that can be put on 'Before Browse' to disable clicks (in this case, the first ten rows), but it could be conditionally on any of the rows/column values..
Disabling things this way means you only run it on rows of the current page.
Code: Select all
$s = "
function nuLoadThis(){
var x = 0;
//-- loop through all valid rows
while($('#rw'+ nuXPad(x) + '0').length > 0){
if(x < 10){
var y= 0;
//-- loop through all valid columns
while($('#rw00' + y).length > 0){
$('#rw'+ nuXPad(x) + y).attr('onclick',null);
console.log(nuGridValue(x, y,'N / A'));
y++;
}
}
x++;
}
}
function nuGridValue(x, y, v){
if($('#rw'+ nuXPad(x) + y).length == 0){
return '';
}
if(arguments.length == 3){
$('#rw'+ nuXPad(x) + y).html(' '+v+' ');
}
var nv = String($('#rw'+ nuXPad(x) + y).html().substr(9));
return nv.substr(0, nv.length-11);
}
function nuGridCss(x, y, s, v){
var adjustY = y + 1;
if($('#rw'+ nuXPad(x) + y).length == 0){
return '';
}
if(arguments.length == 4){
$('#rw'+ nuXPad(x) + y).css(s, v);
}
return $('#rw'+ nuXPad(x) + y).css(s);
}
function nuXPad(value) {
return String(Math.pow(10,2 - String(value).length)).substr(1)+String(value);
}
";
addJSfunction($s);
Steven