tag:blogger.com,1999:blog-8705297068966115777.post1780477250766663589..comments2023-07-03T13:51:23.493+05:30Comments on SharePoint Kings: Redirection from event handlerParth Patelhttp://www.blogger.com/profile/05132175585607358084noreply@blogger.comBlogger43125tag:blogger.com,1999:blog-8705297068966115777.post-33116166033006285612012-01-22T20:09:20.431+05:302012-01-22T20:09:20.431+05:30where you had write your code for redirection mean...where you had write your code for redirection means how you set error page?<br /><br />does your debug point hit in event handler?SharePoint Kingshttps://www.blogger.com/profile/08472838332009399790noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-12369320421614251842012-01-20T19:07:09.670+05:302012-01-20T19:07:09.670+05:30hi,
i am able to redirect to my custom error page...hi,<br /><br />i am able to redirect to my custom error page when i delete item from ribbon but when i try to redirect page when i click delete option through context menu it redirects to sharepoint default error page<br /><br />does anybody has a solution for this<br /><br />thanksAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-82532447419844817222011-08-30T15:58:21.119+05:302011-08-30T15:58:21.119+05:30no we had not tried web event in 2010 for redirect...no we had not tried web event in 2010 for redirection yet.SharePoint Kingshttps://www.blogger.com/profile/08472838332009399790noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-85811153588360369262011-08-30T14:52:15.697+05:302011-08-30T14:52:15.697+05:30Hi, your post is interesting.
I have quick quest...Hi, your post is interesting. <br /><br />I have quick question.<br />Have you tried webadding and webprovisoned in sp2010.<br /><br />if you tried how to overwrite redirection to site welcome page with our custom page. <br /><br />knowsharepoint@gmail.com<br />mkdAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-12890327902968689002011-01-03T23:03:34.557+05:302011-01-03T23:03:34.557+05:30not tried in 2010 yet
but will try soon and let yo...not tried in 2010 yet<br />but will try soon and let you know soonSharePoint Kingshttps://www.blogger.com/profile/08472838332009399790noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-58015219739295496592011-01-03T20:36:02.440+05:302011-01-03T20:36:02.440+05:30This apears to not work in SharePoint 2010 in a do...This apears to not work in SharePoint 2010 in a document lib.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-33765301058253967522010-04-27T12:58:31.748+05:302010-04-27T12:58:31.748+05:30Hi,
I've tried this. It worked when I edited ...Hi,<br /><br />I've tried this. It worked when I edited the listitem, but it didn't work when I made changes into the word document, and saved it again.<br /><br />Kind regardsHans Rnoreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-41758661913343680742010-04-26T22:43:15.494+05:302010-04-26T22:43:15.494+05:30@Hans R,
what we understood, you have to add/upda...@Hans R,<br /><br />what we understood, you have to add/update item/document, that will start the workflow and you have to redirect user to that page.<br /><br />if that is the case,<br />then what we think is you can do something like this.<br />after adding item wait for some time, use threding.sleep then check that item has workflow or not, then if yes then check its status then find task of that workflow then redirect to that task item.<br /><br />it should work atleast theoretically.SharePoint Kingshttps://www.blogger.com/profile/08472838332009399790noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-35430819803162497072010-04-26T15:06:07.393+05:302010-04-26T15:06:07.393+05:30Hi,
I checked the comments and they helped me a l...Hi,<br /><br />I checked the comments and they helped me a little further. I'm still facing the problem that it's not redirecting when a word document is being edited.<br /><br />In my case, I need to redirect to the initiation form of a workflow after the document has been edited.<br /><br />Any idea's?<br /><br />Kind regards.Hans R.noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-53030703676734349352010-04-26T14:33:16.748+05:302010-04-26T14:33:16.748+05:30Hi,
The comments where indeed helpfull.
I used th...Hi,<br /><br />The comments where indeed helpfull.<br />I used the solution from Manoj, and this helpt. But did not solved it :)<br /><br />This code doesn't work when you are updating a word document. I need to redirect to a page (so I can start a workflow on the initiation form) after a word document is updated.<br /><br />Any idea's?<br /><br />Kind regards.Hans R.noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-57946977925078844352010-04-23T21:20:27.584+05:302010-04-23T21:20:27.584+05:30Hans,
you can check comments. that might be resol...Hans,<br /><br />you can check comments. that might be resolve your problem.SharePoint Kingshttps://www.blogger.com/profile/08472838332009399790noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-65973886959334240032010-04-23T19:47:09.754+05:302010-04-23T19:47:09.754+05:30Hi,
I used this article to resolve my problem. I ...Hi,<br /><br />I used this article to resolve my problem. I need to redirect to a page after the item is updated.<br /><br />But can't get it to work.<br />Any help for the event itemupdating please? :)<br /><br />Kind regards,<br />HansHans R.noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-12937845201231591172010-01-27T21:07:27.803+05:302010-01-27T21:07:27.803+05:30We tried the suggestion with the manually saving o...We tried the suggestion with the manually saving of the item in itemadding, but we need to handle the attachments as well.<br /><br />Manoj's code work with small attachment, but the sleeping time is too short for big attachment and you can not force the user to wait 30 second for every itempost.<br /><br />Are there a good way to handle the attachments manually?enteryhttps://www.blogger.com/profile/06250737136355545640noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-12511936255686537402010-01-20T22:48:29.589+05:302010-01-20T22:48:29.589+05:30Radi,
have tried with removing that field with co...Radi,<br /><br />have tried with removing that field with content type.<br /><br />because there should be no relation between content and redirection. there might be something else that is causing your problem.<br /><br />because what we are doing is simple adding item programmatically and by adding item programmatically, there should not be any redirection.<br /><br />so try then with removing that field then if problem persist then it should be some other problem.SharePoint Kingshttps://www.blogger.com/profile/08472838332009399790noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-19148968162741444402010-01-20T15:51:28.271+05:302010-01-20T15:51:28.271+05:30Hi.
The code work, but I have strange problem wit...Hi.<br /><br />The code work, but I have strange problem with Date and Time fields.<br />I have custom list with 3 different content type. If the content type contain a Date and Time filed the new item is saved, but the user go to AllItems.aspx(default behavior), not to redirect url. It look like if I have Date Time field in Content time redirect command doesn't work. Can anyone help me with this problem?Radinoreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-44702816794807030882009-09-26T20:39:47.050+05:302009-09-26T20:39:47.050+05:30Kranthi,
we are not getting your exact requiremen...Kranthi,<br /><br />we are not getting your exact requirement but on event handler you can check your validation and redirect user to some page without saving data, and show your custom massage or pop up, you can do whatever you want in your page.<br /><br />another is you can user SPUtility.TransferToErrorPage Method to shoe sharepoint error page with custom massage.SharePoint Kingshttps://www.blogger.com/profile/08472838332009399790noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-91344161916594651302009-09-24T10:03:20.089+05:302009-09-24T10:03:20.089+05:30actually i need to show a popup meesage to user no...actually i need to show a popup meesage to user not to checkout an image if a workflow is in progress so programming on button click is ruled as i need to do it on item checking can some one suggest me a better waykkhttps://www.blogger.com/profile/10517274622400332439noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-34475657685820114822009-09-22T23:27:11.967+05:302009-09-22T23:27:11.967+05:30Kranthi,
that is not possible from the method des...Kranthi,<br /><br />that is not possible from the method described here.<br /><br />you can put alert on button click of the form by the javascript but can not be done by event handler.SharePoint Kingshttps://www.blogger.com/profile/08472838332009399790noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-49062512974157580332009-09-22T00:52:11.202+05:302009-09-22T00:52:11.202+05:30Is there any way we can show a custom message box ...Is there any way we can show a custom message box when an event is fired and continue with the eventkkhttps://www.blogger.com/profile/10517274622400332439noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-26231207346273291382009-04-08T20:58:00.000+05:302009-04-08T20:58:00.000+05:30I implemented the solution Manoj proposed and I di...I implemented the solution Manoj proposed and I discovered that the reason for the sleep command is to keep the original thread alive long enough for the ItemAdded event receiver to reference the HttpContext object. However, since there is really no way of knowing how long the asynchronous event handler will take, I am uneasy about using that as a solution.<BR/><BR/>In my particular case, I am trying to conditionally redirect to the initiate document approval work flow page when a user selects a checkbox on the editItem.aspx page during a document upload.<BR/><BR/>The problem I am running into is that the form field values have not yet been applied to the properties.ListItem's fields in the ItemUpdating event receiver so I feel forced to redirect in the (asynchronous)ItemAdded event receiver instead. I looked for the checkbox value in properties.AfterProperties as well but the field comes up as null.Erinnoreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-34872104341398169692009-03-27T22:28:00.000+05:302009-03-27T22:28:00.000+05:30Hi varun (akshay) and iyad ,in ItemAdded you will ...Hi varun (akshay) and iyad ,<BR/><BR/>in ItemAdded you will not find httpconotext. <BR/><BR/>you have to add ItemAdding event and fill your static object<BR/>in ItemAdding then you will get that in ItemAdded.Parth Patelhttps://www.blogger.com/profile/05132175585607358084noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-83003543450306836782009-03-27T22:23:00.000+05:302009-03-27T22:23:00.000+05:30hi shreecanth,in item adding you can not find item...hi shreecanth,<BR/><BR/>in item adding you can not find itemid. that is why in our code we are adding item.add and item.update so after that we can get itemid in item adding.<BR/><BR/>but for this you have to go through the code thouroughly. you will get itemid after item.update.Parth Patelhttps://www.blogger.com/profile/05132175585607358084noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-32882854896407178862009-03-10T13:10:00.000+05:302009-03-10T13:10:00.000+05:30Hi Varun did you find solution to your problem? .....Hi Varun did you find solution to your problem? ... cause i have exactly the same issueAnonymoushttps://www.blogger.com/profile/04012139699445159798noreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-20001249168997145962009-01-17T21:53:00.000+05:302009-01-17T21:53:00.000+05:30Hi, nice artile. In my scenario, i have to get...Hi,<BR/> nice artile. In my scenario, i have to get Item Id add redirect to other page. In ItemAdding Item Id is null, here redirection happening. In ItemAdded I am getting Item Id but redirection not happening.<BR/>Please advice me in this regard.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-8705297068966115777.post-5550099161476140432009-01-17T21:48:00.000+05:302009-01-17T21:48:00.000+05:30Hi, thanks for the very good post. In my cas...Hi,<BR/> thanks for the very good post. In my case i need to get the Id of a list item and redirect to other page with Item Id. In ItemAdding Item Id is null here redirection is working. In ItemAdded I am able to get the Item Id but redirection to other page is not happening. Please advice me in this regard.<BR/><BR/>Thanks,<BR/>shreecanth.Anonymousnoreply@blogger.com