Forums

Forums / General Discussions / Stop a form from submitting from server side

Stop a form from submitting from server side

2 posts, 0 answered
  1. Missing user
    Missing user avatar
    18 Jul 2024
    Link to this post
    HI, 
    We have a requirement to validate and check some conditions before a form is submitted. We are disabling the submit button in the UI. However we would like to do an additional check in the server side to make sure all the criteria are met before the form is saved to dynamics. 

    I am able to capture the  ITpcPreMvcFormSubmitEvent Event. However when I return true or false, the form is still submitting to dynamics. How can we avoid the submission and show an error message to user that come criteria are not met to complete the submission. 

    Thanks
    Mahesh
  2. Missing user
    Missing user avatar
    18 Jul 2024 in reply to Missing user
    Link to this post
    Hi Mahesh,

    Perhaps you could try a rule manager that on using the pre-submit condition launches your code and see if that solves the issue.
2 posts, 0 answered