Hello. I have disabled a line level Location field...
# suitescript
n
Hello. I have disabled a line level Location field using User Event. I have written a CS to source the value from the body Location field to this line level location field - which is also working. However, when it sets the value on the line level field, it gets enabled again. What is the cause of this?
m
Why don't you disable again after setting the value ...that would work
n
I have disabled the field in the userevent beforeload event. For disabling in client script, that line need to be committed first.
@battk any help?
n
Maybe don't do it in a client script, set the values in a UE before submit / aftersubmit?
n
But why is it enabling the field after setting it? I am doing the same with Price Level field, defaulting to a price level when an item is selected. It is also disabled via UE before load. It does not get enable.
@NElliott any thoughts?
@reptar any thoughts on this?
b
i would say try using a native field's sourcing and filtering to accomplish this
if not, use suitescript 1 to disable the field, it doesnt have line restrictions for sublist fields
and you can mix ss1 with ss2 if you really want
n
Thanks @battk. That's the last resort. SS 1.0 to the rescue!
They should have made a pure 2.0 alternate for nlapiDisableLineItemField()