Skip to main content

Used this post by: @MegaJerk to take contents of each repeating section and put into table in column (there are two repeating sections on my form).

Issue: I tried to set up what this posting showed but the data from the repeating sections are not showing up as tables in columns.

Environment: Nintex O365

Form fields (See Form1858Image.gif file)

Custom Javascript is attached (customJS.txt)

 

the code almost looks good, but you have commented out a few lines in such a way that it will break if placed inside of a Nintex Form directly. You cannot use the "//" style comments when working JS that is being embedded into the Nintex Form via the Custom JavaScript dropdown in the form settings.



 



This breaks:



var rsToTableConfig = {

"repeatingSections": {

"rsAddEmployee": {

"controls": {

"AddRowNum": "Row",

"AddFName": "First Name",

"AddLName": "Last Name",

"AddEAddress": "E-mail",

"AddPermissions": "Permissions",

"AddNewUser": "New User"

},

"targetMLT": "AddChangeRS_Table",

//"tableClass": "tableData_RS1"

},

"rsRemoveEmployee": {

"controls": {

"RemoveRowNum": "Row",

"RemoveFName": "First Name",

"RemoveLName": "Last Name",

"RemoveEAddress": "E-mail"

},

"targetMLT": "RemoveRS_Table",

//"tableClass": "tableData_RS2"

}

}

};


 



Additionally you shouldn't remove the tableClass property from the object because code is relying on it to exist, which is likely causing another issue. If you don't want a class being applied for some reason, then simply leave the value set to a blank string like:



var rsToTableConfig = {

"repeatingSections": {

"rsAddEmployee": {

"controls": {

"AddRowNum": "Row",

"AddFName": "First Name",

"AddLName": "Last Name",

"AddEAddress": "E-mail",

"AddPermissions": "Permissions",

"AddNewUser": "New User"

},

"targetMLT": "AddChangeRS_Table",

"tableClass": ""

},

"rsRemoveEmployee": {

"controls": {

"RemoveRowNum": "Row",

"RemoveFName": "First Name",

"RemoveLName": "Last Name",

"RemoveEAddress": "E-mail"

},

"targetMLT": "RemoveRS_Table",

"tableClass": ""

}

}

};


 



I would also recommend for testing to turn off any formatting rules that are hiding the two MLT controls (AddChangeRS_Table and RemoveRS_Table) just so that you might better see if anything is happening. 



 



Last but not least, if you go to your form and press F12, it will open the Developer Console, in which any JavaScript errors should be shown inside of it. If you can take a screenshot of any red-colored error inside of there it would be useful for future debugging if this code change still doesn't get it to work. 



 



 


I fixed the // comments and TableClass



Lots of Red errors for 'Refused to load..." or "Refused to get..." see attached.


None of those errors seem to be related to my code, what I would do if I were you would be to setup a test List exactly how the other example shows, and use those instructions to see if you can get it working. That way you have a good working understanding of maybe what's broken here in your main form. 

There seems to be a lot of js errors happening but for unrelated libraries. Are you loading lots of other custom JS? If so, it might be conflicting with something or erroring out and prevent anything from running! Starting with a blank list form will at least let you get everything setup and working in a way where you might know what to look for. 



 



 


Reply