Hi Alexander,
I have these buttons in EditForm:
<input id="btnAction1" class="customBtn" type="button" value="ACTION1" onclick="fnAction1();return false;">
<input id="btnAction2" class="customBtn" type="button" value="ACTION2" onclick="fnAction2();return false;">
<input id="btnAction3" class="customBtn" type="button" value="ACTION3" onclick="fnAction3();return false;">
<input id="btnAction4" class="customBtn" type="button" value="ACTION4" onclick="fnAction4();return false;">
each button fill different values to form and call submit.
Is it possible redirect user to different locations (different views) after submitting depending on which button was use?
Is it possible to change Source= parameter in url?
I tried to add this line
$(location).attr('href', 'https://sharepointtest/sites/DocLibraryTest/Forms/NOK.aspx');
it is working, but when there is some error in form at submitting (eg missing required field) – form is redirected immediatelly without possibility to correct form.
Many thanks
Michal