ServiceNow Certified System Administrator — Question 258
A customer wants to use a client script to validate things on a form in order to make sure the submission makes sense. What type of client script would you recommend to meet this requirement?
Answer options
- A. onSubmit()
- B. onSubmission()
- C. onUpdate()
- D. onLoad()
Correct answer: A
Explanation
The onSubmit() client script is specifically designed to validate form data before it is sent for processing, making it the ideal choice for this scenario. The other options, such as onSubmission() and onUpdate(), do not exist or serve different purposes, while onLoad() is used for actions that occur when the form loads, not during submission.