I have igMaskEditor in mvc, I need when change combo the igMaskEditor change the input mask I use javascript for that but i cant do this
Control
@(Html.Infragistics().MaskEditorFor(m => m.Cliente)
.ID("txtIdentificacion").Render())
I tried change the input mask
$("#txtIdentificacion").igMaskEditor('option', 'inputMask', mascara);
Error
This option can not be set runtime
Please help me
Hello.
This option cannot be changed at runtime, by design, and the error says that. You need to recreate the control in order to change the option value.
Best regards,
Nikolay Alipiev
Hello,
I experienced the same issue after upgrading to 15.2 using javascript to reset the inputMask of the igMaskEditor then following your advice to recreate the control I encountered another problem;
When I execute the $('#txtMaskText').igMaskEditor('destroy'); method I receive an error: Sys.ParameterCountException: Parameter count mismatch.
Can you please point me into the right direction or maybe I am misunderstand you advice to "recreate" the control?
My code;
$("#txtMaskText").igMaskEditor({ width: 160, inputMask: "CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC", nullText: "Enter Value"});
error trace;
"Sys.ParameterCountException: Sys.ParameterCountException: Parameter count mismatch.\n at String$trim (http://localhost:57120/ScriptResource.axd?d=D9drwtSJ4hBA6O8UhT6CQsgs2fQprVMCTtj3BeNLkmNYZ3YEny0GLMh0bRNHLHKwsqJyE9TGAEocHbZnDkNp4WJNZTnw9vfv2T16EPgttPFq0sGI_9O9T9LTMfhMS5jYTICPCSSDrqVf9JXRdQ4WwbErzevELwsgTn_j2jNnI4w1&t=ffffffff88e65ea0:500:33)\n at _removeAttributes (http://localhost:57120/IgniteUI_1502_cust/infragistics.js:356:7359)\n at Anonymous function (http://localhost:57120/Scripts/jquery-ui-1.10.4.min.js:6:4985)\n at _restoreDOMStructure (http://localhost:57120/IgniteUI_1502_cust/infragistics.js:356:6762)\n at Anonymous function (http://localhost:57120/Scripts/jquery-ui-1.10.4.min.js:6:4985)\n at destroy (http://localhost:57120/IgniteUI_1502_cust/infragistics.js:356:11973)\n at Anonymous function (http://localhost:57120/Scripts/jquery-ui-1.10.4.min.js:6:4985)\n at Anonymous function (http://localhost:57120/Scripts/jquery-ui-1.10.4.min.js:6:5940)\n at each (http://localhost:57120/Scripts/jquery-2.1.0.min.js:2:2870)\n at o.prototype.each (http://localhost:57120/Scripts/jquery-2.1.0.min.js:2:809)"
Regards,
Nathan
$('#txtMaskText').igMaskEditor('destroy');