Solved

Unexpected end of file looking for </asp:Content> tag.

Posted on 2011-02-18
7
4,928 Views
Last Modified: 2016-10-03
I've modified an editform.aspx form in SharePoint Designer. I modified the dispform.aspx which works perfectly but the Edit form throws up this error:
An error occurred during the processing of /ess/Lists/Team Member Service Form/EditForm_copy(1).aspx. Unexpected end of file looking for </asp:Content> tag.
What I modified was highlighting 5 fields with a yellow background, deleting a row and adding a new one.

When I go back into designer, it points to this section:
<asp:Content ContentPlaceHolderId="PlaceHolderPageTitle" runat="server">
      <SharePoint:ListFormPageTitle runat="server"/>
</asp:Content>


What can I be doing wrong here?
editformcopy.txt
0
Comment
Question by:mylogo
  • 5
7 Comments
 
LVL 5

Expert Comment

by:navdeepmadan
ID: 34931558
1) Remove the ZoneTemplate and webpartzone closing tag after the PlaceHolderBodyRightMargin

<asp:Content ContentPlaceHolderId="PlaceHolderBodyRightMargin" runat="server">
<div class='ms-areaseparatorright'><IMG SRC="/_layouts/images/blank.gif" width=8 height=100% alt=""></div>
</asp:Content>
</ZoneTemplate></WebPartPages:WebPartZone></asp:Content>

2) Zone template should come inside the web part zone

<asp:Content ContentPlaceHolderId="PlaceHolderMain" runat="server">
<table cellpadding=0 cellspacing=0 id="onetIDListForm">
 <tr>
  <td>
 <WebPartPages:WebPartZone runat="server" FrameType="None" ID="Main" Title="loc:Main">
      </WebPartPages:webpartzone><ZoneTemplate>
0
 

Author Comment

by:mylogo
ID: 34933457
I'm sorry. It's now pulling up the form but giving me a web part error. I think i put it in the wrong place. Does part (2) replace part (1), which is at the end of the code? or at the beginning of the code?
0
 

Author Comment

by:mylogo
ID: 34935193
Please disregard this last post.
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 

Author Comment

by:mylogo
ID: 34935479
Ok, I modified my editform.aspx page with highlighting the few fields i needed to. Works perfectly. The problem i was having was with a text field i was trying to add in designer. I added a merged row to display this text: "Information below should only be entered if changes to Department, Job Title, ..."

This row is what causes my problem with the closing tag. Should i be adding this text a different way? I don't want a field. I only want the text to display in order to separate these fields from the others. Works perfectly on the DispForm.aspx page.
0
 

Accepted Solution

by:
mylogo earned 0 total points
ID: 34935723
I've created a workaround on the edit form by adding a text field. The Display form field I added a row then entered the text. When I tried to do the same in the Edit form, I kept getting the error about the closing ZoneTemplate tag.

I have to believe the workaround is not ideal but adding the row is my downfall on the Edit form.

Is there a fix or do i have to deal with the workaround and the 2 different views?
DispForm.aspx
EditForm.aspx
0
 

Author Closing Comment

by:mylogo
ID: 35042764
Workaround works and unfortunately, no more time available to work on this one piece.
0
 

Expert Comment

by:Chris Cordner
ID: 41826607
Hi

I had a similar problem with a form I was trying to edit, but I have no idea what I have missed. Can anybody help me with this one?

I was playing about with it because I wanted to add a row for the field 'Requested By'. That came up with these errors, so I deleted the row that I had added, thinking that would cure it (albeit without adding the field) but the problem still occurred when I'd done that!

Any help or guidance would be appreciated.

Thanks
Chris
NewFormCopy.aspx
0

Featured Post

The Eight Noble Truths of Backup and Recovery

How can IT departments tackle the challenges of a Big Data world? This white paper provides a roadmap to success and helps companies ensure that all their data is safe and secure, no matter if it resides on-premise with physical or virtual machines or in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This collection of functions covers all the normal rounding methods of just about any numeric value.
I thought I'd write this up for anyone who has a request to create an anonymous whistle-blower-type submission form created using SharePoint 2010 (this would probably work the same for 2013). It's not 100% fool-proof but it's as close as you can get…
The viewer will learn how to use the =DISCRINV command to create a discrete random variable, use this command to model a set of probabilities and outcomes in a Monte Carlo simulation, and learn how to find the standard deviation of a set of probabil…
The viewer will learn how to use a discrete random variable to simulate the return on an investment over a period of years, create a Monte Carlo simulation using the discrete random variable, and create a graph to represent the possible returns over…

786 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question