- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-16-2022 01:03 PM
I have a catalog item that opens with one mandatory variable, a choice list, visible. Depending on which option is taken, other variables are exposed. If certain of the choices on the initial variable are taken we don't want the requestor to be able to submit the request.
The initial variable is mandatory, but since a choice has been taken that condition is met. Is there any way other than trapping via an On Submit CCS that I can prevent the user from submitting the request, e.g. dsiable the submit button?
Thanks for any suggestions.
:{)
:{)
Helpful and Correct tags are appreciated and help others to find information faster
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-16-2022 04:11 PM
Hi again,
Tested it in my instance. I've created a field of type "Yes/No" to trigger to display or hide the "Submit" button
onChange() script on variable "error_selection" that I'm using to toggle to display or hide.
I've disabled "Isolate script" an set UI Type to "All".
function onChange(control, oldValue, newValue, isLoading) {
if (newValue == '') {
return;
}
if (newValue == 'Yes') { // hide submit button
if (window == null) { // service portal
var z = this.document.getElementsByClassName("btn btn-primary btn-block ng-binding ng-scope");
z[0].style.display = 'none';
} else { // ui platform
document.getElementById("oi_order_now_button").style.display = 'none';
}
} else { // display submit button
if (window == null) { // service portal
var y = this.document.getElementsByClassName("btn btn-primary btn-block ng-binding ng-scope");
y[0].style.display = 'initial';
} else { // ui platform
document.getElementById("oi_order_now_button").style.display = 'initial';
}
}
}
Execution results
1. Portal
Case display submit button
Case hide submit button
2. UI16
Case display submit button (using the default "Order Now" button)
Case hide submit button
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-16-2022 01:10 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-16-2022 03:45 PM
Hi John,
It's not possible to "disable" a submit button but it is possible to "hide" it.
Not sure if the content of the following pages are still valid.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎06-16-2022 04:11 PM
Hi again,
Tested it in my instance. I've created a field of type "Yes/No" to trigger to display or hide the "Submit" button
onChange() script on variable "error_selection" that I'm using to toggle to display or hide.
I've disabled "Isolate script" an set UI Type to "All".
function onChange(control, oldValue, newValue, isLoading) {
if (newValue == '') {
return;
}
if (newValue == 'Yes') { // hide submit button
if (window == null) { // service portal
var z = this.document.getElementsByClassName("btn btn-primary btn-block ng-binding ng-scope");
z[0].style.display = 'none';
} else { // ui platform
document.getElementById("oi_order_now_button").style.display = 'none';
}
} else { // display submit button
if (window == null) { // service portal
var y = this.document.getElementsByClassName("btn btn-primary btn-block ng-binding ng-scope");
y[0].style.display = 'initial';
} else { // ui platform
document.getElementById("oi_order_now_button").style.display = 'initial';
}
}
}
Execution results
1. Portal
Case display submit button
Case hide submit button
2. UI16
Case display submit button (using the default "Order Now" button)
Case hide submit button
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-11-2023 11:42 PM
Hi Hitoshi,
How can I hide this submit button from now mobile app also. Can you please give me the solution for this.