Adding File attachments to a list in the custom form


  • Hi,

    I have added Dataview to a custom form using Sharepoint Designer. My form has 3 different modes-view, insert and edit.
    In the insert/edit mode, I am trying to add an attachment file to the list item  using the below code. 

    <SharePoint:FormField runat="server" id="ff6{$Pos}" ControlMode="Edit" FieldName="Attachments" ItemId="{@ID}" __designer:bind="{ddwrt:DataBind('u',concat('ff6',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Attachments')}" />
    <SharePoint:FieldDescription runat="server" id="ff6description{$Pos}" FieldName="Attachments" ControlMode="Edit" />

    This display nothing in the form. How to add an attachment file to a list item.  Thank you.
    Friday, August 29, 2008 8:51 PM


  • Hi,

    SharePoint Designer does not support adding attachment in customized form.


    If you want to use attachment function, please use the Attach File button in the Form Tool bar.


    Here is the code sample in the SharePoint Designer 2007:

    <SharePoint:FormToolBar runat="server" ControlMode="New"/>


    If you were customizing the NewForm.aspx, I suggest you to review this article to make sure the steps of customizing the NewForm.aspx.;NewFormaspx-and-quot;_page_for_a_SharePoint_List.aspx


    Hope the information can be helpful.


    Posting is provided "AS IS" with no warranties, and confers no rights.
    Tuesday, September 02, 2008 8:32 AM

All replies