locked
Placing a custom web part within an item page RRS feed

  • Question

  • I wish to place a custom web part inside an item page,
    in that I would click on an item within a list - accounts for example,

    and end up on the item page - which will have fields such as title, primary contact, email etc..

    However, below, I would like to be able to show a few custom web parts -
    task , contacts etc. The web parts will show tasks and contacts for that item only.

    Is this possible?

    If not, can anyone provide an alternative solution that would allow me to show all the tasks , contacts etc in a separate area below the "static" information.

    In Seperate boxes if you get my drift..

    Friday, July 27, 2012 12:24 PM

All replies

  • It is possible to that as your requirement. You can modify and add new web parts to the DispForm.aspx, or EditForm.aspx (also NewForm.aspx). You can navigate to edit those pages from navigation to the list, and then selecting the edit forms option in the top ribbon.

    For your custom web parts, you can refer the selected current item from the current context ( SPContext.Current.ListItem). That will give you the current list item what is getting edited or displayed. After you getting the current item you can query other Task or the other necessarily lists and show the required data in the Custom web part.

    Friday, July 27, 2012 2:38 PM