locked
unable to see design of custom list form RRS feed

  • Question

  • Hi,

    I create CustomList form and save it on associated list folder, but I can’t  see design view of CustomList form on sharepoint designer, it show me Master Page error:

    “The page contains markup that is not valid when attached to a Master Page.

    Correct the problem in Code view.”

    Why this is happen in some of sharepoint site(not all of them)?! How I can solve it?

    Thanx.

     

    Saturday, May 21, 2011 7:52 PM

All replies

  • What does the source for your custom form look like? 
    The SharePoint Hillbilly
    Fewer Big Words... More Pretty Pictures... http://www.SharePointHillbilly.com
    Saturday, May 21, 2011 8:49 PM
  • Hi Mark.

    My source code like this:

    ***************************************************************

    <%@ Page language="C#" MasterPageFile="~masterurl/default.master"    Inherits="Microsoft.SharePoint.WebPartPages.WebPartPage,Microsoft.SharePoint,Version=12.0.0.0,Culture=neutral,PublicKeyToken=71e9bce111e9429c" meta:progid="SharePoint.WebPartPage.Document" title="| SiteRules" %>
    <%@ Register Tagprefix="SharePoint" Namespace="Microsoft.SharePoint.WebControls" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Register Tagprefix="Utilities" Namespace="Microsoft.SharePoint.Utilities" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> <%@ Import Namespace="Microsoft.SharePoint" %> <%@ Register Tagprefix="WebPartPages" Namespace="Microsoft.SharePoint.WebPartPages" Assembly="Microsoft.SharePoint, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>
    <asp:Content ContentPlaceHolderId="PlaceHolderPageTitle" runat="server">
     <SharePoint:ListFormPageTitle runat="server"/>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderPageTitleInTitleArea" runat="server">
     <SharePoint:ListProperty Property="LinkTitle" runat="server" id="ID_LinkTitle"/>:
     
     <SharePoint:ListItemProperty id="ID_ItemProperty" MaxLength=40 runat="server"/>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderPageImage" runat="server">
     <IMG SRC="../../../_layouts/images/blank.gif" width=1 height=1 alt=""></asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderLeftNavBar" runat="server"/>
    <asp:Content ContentPlaceHolderId="PlaceHolderTitleLeftBorder" runat="server">
    <table cellpadding=0 height=100% width=100% cellspacing=0>
     <tr><td class="ms-areaseparatorleft">
        <IMG SRC="../../../_layouts/images/blank.gif" width=1 height=1 alt=""></td></tr>
    </table>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderTitleAreaClass" runat="server">
    <script id="onetidPageTitleAreaFrameScript">
     document.getElementById("onetidPageTitleAreaFrame").className="ms-areaseparator";
    </script>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderBodyAreaClass" runat="server">
    <style type="text/css">
    .ms-bodyareaframe {
     padding: 8px;
     border: none;
    }
    </style>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderBodyLeftBorder" runat="server">
    <div class='ms-areaseparatorleft'>
        <IMG SRC="../../../_layouts/images/blank.gif" width=8 height=100% alt=""></div>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderTitleRightMargin" runat="server">
    <div class='ms-areaseparatorright'>
        <IMG SRC="../../../_layouts/images/blank.gif" width=8 height=100% alt=""></div>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderBodyRightMargin" runat="server">
    <div class='ms-areaseparatorright'>
        <IMG SRC="../../../_layouts/images/blank.gif" width=8 height=100% alt=""></div>
    </asp:Content>
    <asp:Content ContentPlaceHolderId="PlaceHolderTitleAreaSeparator" runat="server"/>
    <asp:Content id="Content1" runat="server" contentplaceholderid="PlaceHolderMain">
       <input name="g_41ee48b0_7681_4eb1_b975_aae33e1d088f$ff11_1$ctl00$ctl00$TextField_spSave" type="HIDDEN" id="g_41ee48b0_7681_4eb1_b975_aae33e1d088f_ff11_1_ctl00_ctl00_TextField_spSave" /><input name="g_41ee48b0_7681_4eb1_b975_aae33e1d088f$ff14_1$ctl00$ctl00$TextField_spSave" type="HIDDEN" id="g_41ee48b0_7681_4eb1_b975_aae33e1d088f_ff14_1_ctl00_ctl00_TextField_spSave" /><WebPartPages:DataFormWebPart runat="server" IsIncluded="True" FrameType="None" NoDefaultStyle="TRUE" ViewFlag="0" Title="ListName" __markuptype="vsattributemarkup" __WebPartId="{B739EBBD-E65D-44C1-80FF-0E7D99DE014B}" id="g_41ee48b0_7681_4eb1_b975_aae33e1d088f" __AllowXSLTEditing="true" WebPart="true" Height="" Width=""><DataSources><SharePoint:SPDataSource runat="server" DataSourceMode="ListItem" UseInternalName="true" selectcommand="&lt;View&gt;&lt;Query&gt;&lt;Where&gt;&lt;Eq&gt;&lt;FieldRef Name=&quot;ContentType&quot;/&gt;&lt;Value Type=&quot;Text&quot;&gt;مورد&lt;/Value&gt;&lt;/Eq&gt;&lt;/Where&gt;&lt;/Query&gt;&lt;/View&gt;" id="_x062f__x0631__x062e__x0648__x0627__x0633__x062a__x0020__x062e__x062f__x0645__x0627__x062a__x0020__x0648__x062f__x0631__x062c__x0020__x062e__x0637__x0627_1"><SelectParameters><WebPartPages:DataFormParameter Name="ListItemId" ParameterKey="ListItemId" PropertyName="ParameterValues" DefaultValue="0"/><WebPartPages:DataFormParameter Name="ListID" ParameterKey="ListID" PropertyName="ParameterValues" DefaultValue="{B1B12CB2-72DC-4323-95E0-1B9041095A24}"/>
          </SelectParameters><DeleteParameters><WebPartPages:DataFormParameter Name="ListItemId" ParameterKey="ListItemId" PropertyName="ParameterValues" DefaultValue="0"/><WebPartPages:DataFormParameter Name="ListID" ParameterKey="ListID" PropertyName="ParameterValues" DefaultValue="{B1B12CB2-72DC-4323-95E0-1B9041095A24}"/>
          </DeleteParameters><InsertParameters><WebPartPages:DataFormParameter Name="ListItemId" ParameterKey="ListItemId" PropertyName="ParameterValues" DefaultValue="0"/><WebPartPages:DataFormParameter Name="ListID" ParameterKey="ListID" PropertyName="ParameterValues" DefaultValue="{B1B12CB2-72DC-4323-95E0-1B9041095A24}"/>
          </InsertParameters><UpdateParameters><WebPartPages:DataFormParameter Name="ListItemId" ParameterKey="ListItemId" PropertyName="ParameterValues" DefaultValue="0"/><WebPartPages:DataFormParameter Name="ListID" ParameterKey="ListID" PropertyName="ParameterValues" DefaultValue="{B1B12CB2-72DC-4323-95E0-1B9041095A24}"/>
          </UpdateParameters>
         </SharePoint:SPDataSource>
     </DataSources>
     <ParameterBindings>
         <ParameterBinding Name="ListItemId" Location="QueryString(ID)" DefaultValue="0"/>
         <ParameterBinding Name="ListID" Location="None" DefaultValue="{B1B12CB2-72DC-4323-95E0-1B9041095A24}"/>
         <ParameterBinding Name="dvt_apos" Location="Postback;Connection"/>
         <ParameterBinding Name="UserID" Location="CAMLVariable" DefaultValue="CurrentUserName"/>
         <ParameterBinding Name="Today" Location="CAMLVariable" DefaultValue="CurrentDate"/>
        </ParameterBindings>
     <datafields>@Title,Caption;@_x0646__x0627__x0645__x0020__x06,UnitName;@_x0646__x0627__x0645__x0020__x060,CenterName;@_x062f__x0631__x062e__x0648__x06,Request;@_x062a__x0644__x0641__x0646__x00,Tel;@_x062a__x0648__x0636__x06cc__x06,Description;@_x0648__x0627__x06af__x0630__x06,AssignTo;@_x062a__x0627__x0631__x06cc__x06,AssignDate;@_x0645__x0647__x0644__x062a__x00,FinishDate;@_x0627__x0644__x0648__x06cc__x06,Priority;@_x062a__x0648__x0636__x06cc__x060,Description2;</datafields><XSL><xsl:stylesheet xmlns:x="http://www.w3.org/2001/XMLSchema" xmlns:dsp="http://schemas.microsoft.com/sharepoint/dsp" version="1.0" exclude-result-prefixes="xsl msxsl ddwrt" xmlns:ddwrt="http://schemas.microsoft.com/WebParts/v2/DataView/runtime" xmlns:asp="http://schemas.microsoft.com/ASPNET/20" xmlns:__designer="http://schemas.microsoft.com/WebParts/v2/DataView/designer" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schemas-microsoft-com:xslt" xmlns:SharePoint="Microsoft.SharePoint.WebControls" xmlns:ddwrt2="urn:frontpage:internal"><xsl:output method="html" indent="no"/><xsl:decimal-format NaN=""/><xsl:param name="dvt_apos">'</xsl:param><xsl:variable name="dvt_1_automode">0</xsl:variable><xsl:template match="/"><xsl:call-template name="dvt_1"/></xsl:template><xsl:template name="dvt_1"><xsl:variable name="dvt_StyleName">ListForm</xsl:variable><xsl:variable name="Rows" select="/dsQueryResponse/Rows/Row"/><div>
       <span id="part1">
        <table border="0" width="100%">
            <xsl:call-template name="dvt_1.body">
                <xsl:with-param name="Rows" select="$Rows"/>
            </xsl:call-template>
        </table>
       </span>
       <SharePoint:AttachmentUpload runat="server" ControlMode="New"/>
       <SharePoint:ItemHiddenVersion runat="server" ControlMode="New"/>
      </div>
     </xsl:template>
        <xsl:template name="dvt_1.body">
            <xsl:param name="Rows"/>
      <tr>
       <td class="ms-toolbar" nowrap="">
        <table>
         <tr>
          <td width="99%" class="ms-toolbar" nowrap=""><IMG SRC="/_layouts/images/blank.gif" width="1" height="18"/></td>
          <td class="ms-toolbar" nowrap="">
           <SharePoint:SaveButton runat="server" ControlMode="New" id="savebutton1"/>
          </td>
          <td class="ms-separator"> </td>
          <td class="ms-toolbar" nowrap="" align="right">
           <SharePoint:GoBackButton runat="server" ControlMode="New" id="gobackbutton1"/>
          </td>
         </tr>
        </table>
       </td>
      </tr>
      <tr>
       <td class="ms-toolbar" nowrap="">
        <SharePoint:FormToolBar runat="server" ControlMode="New"/>
       </td>
      </tr>
            <xsl:call-template name="dvt_1.rowedit">
                <xsl:with-param name="Pos" select="concat('_', position())" />
            </xsl:call-template>
            
      <tr>
       <td class="ms-toolbar" nowrap="">
        <table>
         <tr>
          <td width="99%" class="ms-toolbar" nowrap=""><IMG SRC="/_layouts/images/blank.gif" width="1" height="18"/></td>
          <td class="ms-toolbar" nowrap=""><input type="button" value="تایید" name="btnFormAction" onclick="javascript: {ddwrt:GenFireServerEvent('__commit;__redirect={http://itc.mums.ac.ir/network/Lists/List15/Approve.aspx}')}" style="font-family: tahoma; font-size: 11px; width: 46px;" /></td>
          <td class="ms-separator"> </td>
          <td class="ms-toolbar" nowrap="" align="right">
           <SharePoint:GoBackButton runat="server" ControlMode="New" id="gobackbutton2"/>
          </td>
         </tr>
        </table>
       </td>
      </tr>
     </xsl:template>
        <xsl:template name="dvt_1.rowedit">
            <xsl:param name="Pos" />
            <tr>
       <td>
        <table border="0" cellspacing="0" width="100%">
         <tr>
          <td width="190px" valign="top" class="ms-formlabel">
           <H3 class="ms-standardheader">
            <nobr>Caption<span class="ms-formvalidation"> *</span></nobr></H3>
          </td>
          <td width="400px" valign="top" class="ms-formbody">
           <SharePoint:FormField runat="server" id="ff1{$Pos}" ControlMode="New" FieldName="Title" __designer:bind="{ddwrt:DataBind('i',concat('ff1',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Title')}"/>
           <SharePoint:FieldDescription runat="server" id="ff1description{$Pos}" FieldName="Title" ControlMode="New"/>
          </td>
         </tr>
         <tr>
          <td width="190px" valign="top" class="ms-formlabel">
           <H3 class="ms-standardheader">
            <nobr>UnitName</nobr></H3>
          </td>
          <td width="400px" valign="top" class="ms-formbody">
           <SharePoint:FormField runat="server" id="ff2{$Pos}" ControlMode="New" FieldName="_x0646__x0627__x0645__x0020__x06" __designer:bind="{ddwrt:DataBind('i',concat('ff2',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@_x0646__x0627__x0645__x0020__x06')}"/>
           <SharePoint:FieldDescription runat="server" id="ff2description{$Pos}" FieldName="_x0646__x0627__x0645__x0020__x06" ControlMode="New"/>
          </td>
         </tr>
         <tr>
          <td width="190px" valign="top" class="ms-formlabel">
           <H3 class="ms-standardheader">
            <nobr>CenterName</nobr></H3>
          </td>
          <td width="400px" valign="top" class="ms-formbody">
           <SharePoint:FormField runat="server" id="ff3{$Pos}" ControlMode="New" FieldName="_x0646__x0627__x0645__x0020__x060" __designer:bind="{ddwrt:DataBind('i',concat('ff3',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@_x0646__x0627__x0645__x0020__x060')}"/>
           <SharePoint:FieldDescription runat="server" id="ff3description{$Pos}" FieldName="_x0646__x0627__x0645__x0020__x060" ControlMode="New"/>
          </td>
         </tr>
         <tr>
          <td width="190px" valign="top" class="ms-formlabel">
           <H3 class="ms-standardheader">
            <nobr>Requests</nobr></H3>
          </td>
          <td width="400px" valign="top" class="ms-formbody">
           <SharePoint:FormField runat="server" id="ff4{$Pos}" ControlMode="New" FieldName="_x062f__x0631__x062e__x0648__x06" __designer:bind="{ddwrt:DataBind('i',concat('ff4',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@_x062f__x0631__x062e__x0648__x06')}"/>
           <SharePoint:FieldDescription runat="server" id="ff4description{$Pos}" FieldName="_x062f__x0631__x062e__x0648__x06" ControlMode="New"/>
          </td>
         </tr>
         <tr>
          <td width="190px" valign="top" class="ms-formlabel">
           <H3 class="ms-standardheader">
            <nobr>Tel</nobr></H3>
          </td>
          <td width="400px" valign="top" class="ms-formbody">
           <SharePoint:FormField runat="server" id="ff5{$Pos}" ControlMode="New" FieldName="_x062a__x0644__x0641__x0646__x00" __designer:bind="{ddwrt:DataBind('i',concat('ff5',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@_x062a__x0644__x0641__x0646__x00')}"/>
           <SharePoint:FieldDescription runat="server" id="ff5description{$Pos}" FieldName="_x062a__x0644__x0641__x0646__x00" ControlMode="New"/>
          </td>
         </tr>
         <tr>
          <td width="190px" valign="top" class="ms-formlabel">
           <H3 class="ms-standardheader">
            <nobr>Description</nobr></H3>
          </td>
          <td width="400px" valign="top" class="ms-formbody">
           <SharePoint:FormField runat="server" id="ff6{$Pos}" ControlMode="New" FieldName="_x062a__x0648__x0636__x06cc__x06" __designer:bind="{ddwrt:DataBind('i',concat('ff6',$Pos),'Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@_x062a__x0648__x0636__x06cc__x06')}"/>
           <SharePoint:FieldDescription runat="server" id="ff6description{$Pos}" FieldName="_x062a__x0648__x0636__x06cc__x06" ControlMode="New"/>
          </td>
         </tr>
         <tr id="idAttachmentsRow">
          <td width="20%" valign="top" class="ms-formlabel" nowrap="true"><SharePoint:FieldLabel ControlMode="New" FieldName="Attachments" runat="server" /></td><td valign="top" class="ms-formbody" width="80%"><SharePoint:FormField runat="server" id="AttachmentsField" ControlMode="New" FieldName="Attachments" __designer:bind="{ddwrt:DataBind('i','AttachmentsField','Value','ValueChanged','ID',ddwrt:EscapeDelims(string(@ID)),'@Attachments')}" /><script /></td></tr>
            <xsl:if test="$dvt_1_automode = '1'" ddwrt:cf_ignore="1">
          <tr>
           <td colspan="99" class="ms-vb">
            <span ddwrt:amkeyfield="ID" ddwrt:amkeyvalue="ddwrt:EscapeDelims(string(@ID))" ddwrt:ammode="view"></span>
           </td>
          </tr>
         </xsl:if>
        </table>
       </td>
      </tr>
            
     </xsl:template>
    </xsl:stylesheet> </XSL>
    </WebPartPages:DataFormWebPart>
    </asp:Content>

    ************************************************************

    i'm very appriciated if you help me to solve this problem.

    thanx.

    Monday, July 11, 2011 10:25 AM