Solved

How to redirect to URL in Sharepoint workflow?

Posted on 2011-09-29
6
2,041 Views
Last Modified: 2012-05-12
I want to redirect to a URL in workflow.
For example, if condition A, redirect to URL A
else if condition B, redirect to URL B.
Any idea how can do that?
Thank you.

Environment:
WSS 3, SPD 2007.
0
Comment
Question by:dickchan
  • 3
  • 2
6 Comments
 
LVL 14

Expert Comment

by:GeorgeGergues
ID: 36899596
I don't think I understand your question .

The workflow (as defined by the SharePoint Desinger or Visual Studio ) does not use http post or get or redirect commands.

can you let me know what are you trying to do and put some screen shots , that would help.

Best of luck.
0
 
LVL 9

Accepted Solution

by:
Ivan Padabed earned 250 total points
ID: 36899790
SP workflows are executing out of web context. if you need to redirecr user based on value entered in NewForm or EditForm, you have to customize corresponded form to have your own OnSubmit handler; it should update an item and then perform redirect
0
 
LVL 5

Assisted Solution

by:tzarad
tzarad earned 250 total points
ID: 36903773
For what you intend to to you need to use event handler
see this link
0
Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

 
LVL 9

Expert Comment

by:Ivan Padabed
ID: 36903828
wow tzarad, could you please write a code sample redirecting user browser in Event Receiver? It will be really appreciated, in my 6 year dev experience in SP I've never seen such approach. I believe that you didn't get the question right.
0
 
LVL 5

Expert Comment

by:tzarad
ID: 36904904
May be I didn't understand it :) But an option seems to be cancelling the event and redirect to a custom page link
One thing is sure, you will not be redirected by a workflow action, so you have to modify the code behind your New or Edit Item form using Sharepoint Designer if you don't want to use the redirect option in the cancelevent.
0
 
LVL 9

Expert Comment

by:Ivan Padabed
ID: 36910795
make sense, thanks for the link tzarad. but drawback here is that item will not be updated if we use CancelWithRedirect. Not sure if this is acceptable but it is an option.
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Last week I faced a strange issue recently, i have deployed SharePoint 2003 servers for one project and one of the requirements was to open SharePoint site from same server. when i was trying to open site from the same server i was getting authentic…
For SharePoint sites, particularly public-facing ones, there are times when adding JavaScript, Meta Tags, CSS Styles or other content to the page <head> section is more practical than modifying master pages.  For instance, you could add the jQuery l…
This video discusses moving either the default database or any database to a new volume.
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now