I have several pages that have a link to Add a New Item to a List with an Attachment. Let's say Pages A, B, and C. After the new item has been added and they press Submit, I want the user to go back to their previous page, wherever they started from. If they started on Page A, I want them to go back to Page A. If they started on B, return to B, and so on. I do not want to direct every user to Page X because that's not where they started.
Many links that I have found are outdated and only contain other links that no longer exist.
We are NOT allowed to use InfoPath.
We are NOT allowed to use SharePoint Designer.
We are using SharePoint 2013.
Can anyone please help?
If you look at the url from the "new item" link, it would usually look something like this: http://mynintexdomain/Lists/MRO%20Test%203/NewForm.aspx?Source=http%3A%2F%2Fmynintexdomain%2Fspielwi...=
That doesn't quite work. No matter which page I start from, when I get to the new Form page, it has the appropriate Source=blah%20blah%20PageA or ...PageB or ...PageC identification. Why would I need to encode the Source path if SharePoint does that automatically?
There's only one blank for the Redirect URL entry on the Form itself (Form Settings, Advanced). *This* is what has to be different no matter what page the user starts on. I don't want them to hit the back button, I want the form to automatically send them back there after being submitted.
Where do I define "go back to source" when the form is done? I don't just put "source" in the Redirect URL box, or do I?
Ok, that's what I did:
What happened? I replaced the Source query-string by the relative url /. This is the url of the site root. After submitting the form, SharePoint redirects me to this url (as long as it's within SharePoint). Note that I didn't url-encode the parameter to keep it simple, but usually you should.
What does this mean? If you add a "Source" Parameter to the url, SharePoint will bring you there after submitting the form. This is not a Nintex feature, but a SharePoint feature, but in my test it worked also when using a Nintex form.
And now? You can create a link to a form, which also contains the information about where you want to user to be redirected afterwards. Place a link to the form on your Page A, and make sure it has the query string ?Source=/SitePages/PageA.aspx, and it will bring the user back to Page A after submitting the form. Don't enter anything into the "Redirect URL" Field in the form settings, because the redirection will be handled by SharePoint, not by Nintex.
I tested this on Nintex for SharePoint 2016 with classic forms.
I hope this helps