Repeating controls in javascript script issue


Badge +9

Hi All,

I have  stored the value of a textbox in repeating control  by "Store Client ID in JavaScript variable". In JavaScript I am trying to set the attribute for making the textbox read-only depending upon the value in query string but its is just getting applied on the last row textbox in case of multiple rows. How can I apply the attribute to all textboxes in multiple rows.?


7 replies

Badge +7

Hi,

If you apply a css class to the control you can set them all at the same time using the class instead of the id to identify them in script.

Jan

Badge +9

I want to make them read only and I am not able to do that with css

Badge +7

Hi,

If you try something like this after adding a CSS class of myTextBox to the single line text control it should work...

NWF$(".myTextBox input").attr('readonly', true);

Jan

Badge +9

The script is not working in repeating control textbox

Badge +7

Hi,

Which version of Nintex are you using? I've tried it in a form repeating section and it works for me.

Thanks

Jan

Badge +9

Hi Jan,

My apologies. Actually the rule based on one column condition and somehow it failed due to which the code didn't execute. Now the things are working fine

Badge +7

That's great, glad it's all working for you.

Reply