Hi! Is there a way to manipulate the return error/...
# suitescript
j
Hi! Is there a way to manipulate the return error/response upon importing a CSV file?
n
Do you mean via the UI or do you mean via scripting? UI definitely not. Via script, I don't believe you can capture the errors only whether the task has submitted successfully or not and possibly poll the task to see if it's completed. You may find more info looking in help at N/task if that's what you've used.
l
Create User Event
beforeSumit
and apply to the record you’re trying to import with. Than validate everything there, if anything unexpected, use
throw 'Failed, xxxxxx'
to customize your error message
👍 2
make sure you enable server-side script while create csv import