Hello,
I have a scenario and wanted to know if this is possible.
I have a grid field that is declared as string. The content of this field can depending on other attributes either be a string with a defined maxlength or a number with a defined format. In my frist try I have edited this field in a popup window and that worked. Is it possible to achieve this inside the grid?
I have tried this approach, which works for the string with the maxlength, but I cannot get the editor to behave as a jqxNumberInput like in other columns (which are numbers, so I assume that’s the problem):
initeditor: function (row, column, editor) { var data = $('#jqxgrid').jqxGrid('getrowdata', row); if(data.ftid == 1) //Alpha { editor.attr('maxlength', data.fieldlength); } else if(data.ftid == 2) //Numeric { var digits = data.fieldprec - data.fieldscal; var decimalDigits = data.fieldscal; editor.jqxNumberInput({ digits: digits, decimalDigits: decimalDigits, spinButtons: false}); }}
Is there any way to achieve this or is this by design because of the definition number or string?