Requirement: To redirect to another page after checking in
Using the following code in ItemCheckingIn event of SPItemEventReceiver.
public override void ItemCheckingIn(SPItemEventProperties properties)
SPUtility.Redirect ("http://site/XXXX.apsx", SPRedirectFlags.Trusted, CNT_CONTEXT);
Issue: During Check in , the way in which the dedirection is displayed differs when the file is checked out locally(To Local Drafts folder) against when checked out from the server.
- When checked out locally, the validation message is displayed in a JS pop up.
- This is after the Yes/No popup with message like "You are about to upload <file name>. Do you want to continue?"
- Also I see another popup after the validation message one , with text like "The file could not be checked in. It may have already been checkedin by another user."
- The redirection is not running, just stay the check-in page.
- When checked out on the server, it can redirct to another page after check
View Complete Post