Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

is there a way where we can get the link(editform.aspx) of item just added to the list-- in the itemadded method of the event receiver (Share Point object model)

share|improve this question

2 Answers 2

up vote 3 down vote accepted

Following should give you the Url to the edit form:

string editUrl = String.Format("{0}/{1}?ID={2}", properties.WebUrl, properties.List.Forms[PAGETYPE.PAGE_EDITFORM].Url,properties.ListItemId);
share|improve this answer

You should be able to get the SPListItem.URL property of the item in the itemadded event receiver. The URL property gets the site-relative URL of the item.

Hope I have understood your question correctly.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.