The attached document is used by our selection panel and I have been asked if there is a possibility of adding a 'Sort' button. This button will automaticall sort the column 'Total including weighting (if applicable)' column into descending order.
Just wondering if this possible and what the coding would be.
Regards
Jenny
Views
Replies
Total Likes
Views
Replies
Total Likes
You're also iterating through the list in an unexpected way. You won't get the JavaScript errors if you iterate like this:
var rows = xfa.resolveNodes("Detail[*]");
for (var i = 0; i < rows.length; i++) {
rows.item(i).Number.rawValue = i + 1;
}
Views
Replies
Total Likes
Hi Kevin,
I added the Javascript to the 'Sort' Button but came up with an error.
I am a newbe at all this (self taught) and don't really understand what the coding means or what I haven't done.
I have attached what I did.
Your assistance would be greatly appreciated.
Cheers
Jenny
Views
Replies
Total Likes
Hi Jenny,
Yes, you can sort columns in repeatable subforms using JavaScript. It is not a simple scripting task though. We have a working sample of a LCD form that sorts columns at our web site www.pdfscripting.com, but the library of sample scripted files is not a free resource. Since you say you are new to scripting, in addition to the library of scripted sample files you may find the training videos at the site worth the membership fee.
Hope this helps,
Dimitri Munkirs
WindJack Solutions
Views
Replies
Total Likes
Views
Likes
Replies