The Art of SharePoint Evolution

Stories from a SharePoint Engineer that isn’t afraid of Visual Studio.

How to edit the form fields of a SharePoint List

with 30 comments

Here’s an often forgotten feature that any SharePoint Designer person should be aware of. It’s the ability to edit and customize the default form fields for any list. This is made possible by using SharePoint Designer to navigate and open the form page that you want to edit. When you open the page you’ll see something like this:

You’ve probably tried right clicking around, trying to convert the web part to a dataview web part, and then you threw up your hands and said this is impossible!

But wait! Check this out… First select the ListFormWebPart and *EDIT: DO NOT hit the delete key. Instead hide the webpart. If you delete it, this will happen: http://support.microsoft.com/kb/935504

Ta da! Now you can go about your daily business of form customizations.

Written by Henry

September 5, 2007 at 8:55 am

30 Responses to 'How to edit the form fields of a SharePoint List'

Subscribe to comments with RSS or TrackBack to 'How to edit the form fields of a SharePoint List'.

  1. Hi there
    When i remove the title filed i get Error When i creat a new item?
    And if any one know about removing the tiltle filed from list

    thanks

    Hilina

    5 Sep 07 at 11:25 pm

  2. I’ve noticed similar errors also but haven’t had a chance to figure out why. instead, i’ve used custom css to hide the fields i didn’t want instead of deleting it.

    Henry

    6 Sep 07 at 7:24 am

  3. You”ll probably want to modify the content type for the list and use ShowInDisplayForm (or ShowInEditForm) to toggle the display.

  4. Thanks for the tip Oskar, but I’m a bit confused. Where would we be able to find the ShowInDisplayForm property?

    Henry

    6 Sep 07 at 12:46 pm

  5. i can’t click SharePoint controls..how?thnx

    anne

    17 Sep 07 at 11:04 pm

  6. You mean SharePoint Controls from the menu? Have you tried clicking onto a web part zone on the page before that?

    Henry

    18 Sep 07 at 7:52 am

  7. sorry..can u explain to me step by step..i want to edit my list..thnx!

    anne

    18 Sep 07 at 4:27 pm

  8. hey anne,

    make the List Form Web Part invisible. (if you still get the error, you have to recreate the list first)

    put your custom list form inside.

    after that, simply open the web part options and activate the “Hidden” option. thats all

    bacco

    18 Oct 07 at 2:31 am

  9. Hello.

    I have a question regarding hidden fields. Is it possible to have fields (on a SharePoint list form) that are hidden or shown based on the selection made in another drop-down field? Or maybe a hidden sub-form?

    I’ve been looking for a week for an answer to this all over the web, and I can’t seem to find it. Thanks!

    Vlad

    30 Oct 07 at 3:36 pm

  10. i’m thinking some custom javascript on one of the form pages should do the trick.

    Henry

    30 Oct 07 at 10:24 pm

  11. Henry, thanks for the quick answer. Have you seen anything like that out there? If I see it, I may be able to duplicate it. Any thoughts? Thanks again.

    Vlad

    31 Oct 07 at 7:35 am

  12. Hello,

    I am trying what you are saying, however I am still unable to use the Attachment button. I am getting a javascript error stating the the control is not available because it is hidden.

    If this is the case then why not create a new form and import the custom list for into that? It does the same thing and you dont even have to touch the newform.aspx form.

    Thanks for any help

    Andrew

    18 Jan 08 at 2:45 pm

  13. in the above thing i need to make some feilds as read only is ther any posibility in doing this

    uday

    26 Mar 08 at 6:15 am

  14. uday, after you have created your custom form, individually format the “read only” form field as “text” or “rich text” instead of as a list form item.

    ros256

    23 Apr 08 at 12:04 pm

  15. Hi,
    is very useful. But one of my design problems thereby becomes not solved. On a wiki-site the option New Item Form is disabled. And just this I need. Is there an other possibility to do this? Thanks.

    Tobia

    8 May 08 at 12:29 am

  16. Hey Tobia, I’ve also looked into doing this but haven’t found an easy option to edit wiki new form pages.

    Henry

    12 May 08 at 7:46 pm

  17. Hi -

    Thanks - I followed the instructions and customized my NewForm. But when I try to load it, I get an error. Any ideas? :)
    ” Unable to display this Web Part. To troubleshoot the problem, open this Web page in a Windows SharePoint Services-compatible HTML editor such as Microsoft Office SharePoint Designer. If the problem persists, contact your Web server administrator. “

    Tuesday

    15 May 08 at 7:06 am

  18. how do you ‘HIDE” the webpart in sharepoint designer?

    dhx

    28 May 08 at 3:20 pm

  19. Hey dhx, you can right click the web part, click on web part properties and then mark it hidden (one of the check boxes in the settings)

    Henry

    2 Jun 08 at 6:56 pm

  20. Thanks alot for this articale ,and i have a question … in looding this page in your example and set the value of emplyee name automatic so i made this input field disabled by javascript but the sharepoint consider this field is empty ???? meaning , when i make the field disabled sharepoint consider it as empty field any idea ???

    Qassem

    1 Jul 08 at 5:57 am

  21. I have tried the steps listed. However, when I try to insert a custom list, it does nothing. I don’t get an error message or anything. I am trying to edit the newform.aspx.

    Any ideas?

    Georgia

    11 Jul 08 at 7:26 am

  22. Hey Georgia, are you inserting the custom list into a web part zone?

    Henry

    12 Jul 08 at 3:56 pm

  23. Folks, I am trying to mark a field as readonly so the user will not be able to edit it. The field is already populated. Thx

    Catalin

    13 Jul 08 at 7:31 am

  24. Does anyone have any idea how to layout a radio button group for a Choice field in SharePoint so it displays horizontal rather than vertical.

    Dave

    20 Jul 08 at 8:03 pm

  25. hi,
    i did the following steps to get the custom lis form for a custom list i hvae created
    1.Hide the default List Form Web Part from the page.
    2.Go Insert > SharePoint Controls > Custom List Form.
    3.In the List or Document Library Form dialog, select the appropriate list, content type and type of form.
    4. Click OK and a new Data Form Web Part is not added , no error on the page also there is no error in the log files

    shekhar

    28 Aug 08 at 4:10 am

  26. Hi,
    I have a strange behavior.
    When I try to 1-Hide the default List Form Web Part from the page in the small windows I don’t have the control where you can click hide and all the other stuff but I have the page that get display. I try it on an other list and it work but the list I need to change doesn’t.
    On the same list when I tried
    2.Go Insert > SharePoint Controls > Custom List Form.
    3.In the List or Document Library Form dialog, select the appropriate list
    Nothing display in the window with no error but I try the same thing on an other list it work.

    How can I fix my list to be able to create custom page to add, edit and display my data ?

    Thanks,
    Eric

    Eric

    2 Sep 08 at 12:06 pm

  27. Thanks for this posting. I am using and it does exactly what I wanted and it is easy to do.

    I have one question someone might be able to help with. I am using this technique to create a custom display form. In my DispForm, I have a field that is a multi-select people field. It is displaying the HTML code instead of rendering it. How do I need to configure that field so it renders the HTML properly?

    Rich R

    24 Oct 08 at 6:14 am

  28. I answered my own question in case anyone else stumbles across this.

    The display field needs to contain ‘disable-output-escaping=”yes”‘.

    Example:

    Rich R

    24 Oct 08 at 11:45 am

  29. Example in last comment should be as follows within the tags for the field to be displayed:

    xsl:value-of select=”@FieldName_x0020″ disable-output-escaping=”yes”/

    Rich R

    24 Oct 08 at 11:47 am

  30. well, hi admin adn people nice forum indeed. how’s life? hope it’s introduce branch ;)

    cwxwwwxdfvwwxwx

    25 Dec 08 at 4:19 pm

Leave a Reply