Is there a way, without being in isDynamic mode, t...
# suitescript
s
Is there a way, without being in isDynamic mode, to use
getText()
without getting the error
You must use getValue to return the value set with setValue
m
getValue
,
setValue
etc. are used for body fields, so they have nothing to do with the
isDynamic
mode Cheers
s
I'm getting the issue when doing getText for a new record for the terms field
r
Getvalue gives you internalId of the record and getText gives you the text of the record if the field is list/record type. Getvalue gives you text and getText gives you undefined if the field is not list/record type. Basically any other type of field integer/longtext, freeformtext, etc.
s
I am getting an error when doing getText. I was just hoping to get around that error without having to do a search
r
What is the field type?
s
it's terms so it's a dropdown (select)
a
My recommendation stay away/avoid getText as the plague.
👍🏼 1
c
source the value to a free-text field and use that field ID as what you're trying to get. List values sourced into free-text fields should be text.
👍🏼 1
w
try .toString() or youVariableName+’’;