Im finding the performance to be terrible when che...
# suitescript
m
Im finding the performance to be terrible when checking a checkbox on all item lines in a client script. Any suggestions? Im using selectLine then setCurrentSublistValue to set each line
b
you can try stuff like using ignoreFieldChange or ignoreRecalc to try and get minor performance increases
it probably isnt going to be the change you are looking for since it mimics the ui process of selecting a line, changing a field, then committing the line
fastest is using ss1 and use nlapiSetLineItemValue to set all your checkboxes and then nlapiRefreshLineItems to refresh the sublist.
e
Have you tried Sublist.addMarkAllButtons()?
m
Beware that the docs do say that
nlapiSetLineItemValue
won't work. But from personal experience it does
This function can be used in client SuiteScript, but note that it is supported only on custom fields and the Description field. If you use this function to set the value of a standard, built-in line item field, the function will not execute.
s
@battk Are you suggesting that the dev write an entirely new script in 1.0 to check the check boxes?
m
This scripts only job is to check those boxes and is a very simple script so i will rewrite in ss1. @Sean Murphy Sometimes you just gotta do what you gotta do in netsuite 🙂
@Eric B addMarkAllButtons only works on static sublists or lists it says
b
You dont really need to rewrite. You can use ss1 is your ss2 client script