SharePoint - "Invalid Page URL" when clicking "New" on existing Shareppoint List

Asked By joe Smo on 27-Sep-11 12:59 AM
Please help I receive the following message "Invalid URL" when trying to create a new form for an existing list on our SharePoint page. I believe it is the result of deleting a webpart, but I cannot afford to delete the list since it's contents are very sensitive and valuable. Does anyone else know of a safe an effective way to re-estblish the link? Please keep it simple for a novice.

Thanks

S
smr replied to joe Smo on 27-Sep-11 01:07 AM
HI

Reason for the issue : This issue occurs if you deleted the List Form Web Part from the NewForm.aspx page.

Solution : To resolve this issue, delete the list, and then re-create it. Then, customize the NewForm.aspx page. When you customize the NewForm.aspx page, make sure that you do not delete the List Form Web Part.

If you want to customize the controls that appear on the NewForm.aspx page, and if you do not want to show the default List Form Web Part, you can hide the List Form Web Part. To do this, follow these steps:

  1. Start SharePoint Designer 2007, and then open the NewForm.aspx page for the list.
  2. Right-click the List Form Web Part, and then click Web Part Properties.
  3. Expand Layout, click to select the Hidden check box, and then click OK.
joe Smo replied to smr on 27-Sep-11 01:17 AM
John,

Thanks for your reply, but either deleting the list and re-creating sounds like a dangerous undertaking with literally thousands of datapoints existing on this page I cannot afford to lose the existing data. I have seen this soultion before, but it does not speak to existing information. Is there another way or is this easy and I just do not realize it?

Thanks

S
Anoop S replied to joe Smo on 27-Sep-11 01:47 AM

If you click New to create a new item in the list, you receive the following message:
Invalid page URL:

If you click an existing item in the list, you receive the following error message:
An unexpected error has occurred

Additionally, you might view the properties of the list in SharePoint Designer 2007 and then specify the NewForm.aspx page in the New item form box. When you do this, the NewForm.aspx page appears to be saved as the new item form when you click OK. However, the next time that you view the properties of the list, the New item form box is empty.
Back to the top

CAUSE

This issue occurs if you deleted the List Form Web Part from the NewForm.aspx pa...This issue occurs if you deleted the List Form Web Part from the NewForm.aspx page.
Back to the top

RESOLUTION

Method 1:

To resolve this issue, delete the list, and then re-create it. Then, customize t...To resolve this issue, delete the list, and then re-create it. Then, customize the NewForm.aspx page. When you customize the NewForm.aspx page, make sure that you do not delete the List Form Web Part.

Method 2:

  1. Open NewForm.aspx and EditForm.aspx in Sharepoint Designer
  2. Copy the code for the ListFormWebPart control from the EditForm.aspx. The code in question reaches from
    <WebPartPages:ListFormWebPart runat="server" __MarkupType="xmlmarkup" WebPart="true" __WebPartId="{YOUR_GUID}" >
    down to
    </WebPartPages:ListFormWebPart>
  3. Paste it into the broken NewForm.aspx, I pasted it right below the Line:
    <WebPartPages:WebPartZone runat="server" FrameType="None" ID="Main" Title="loc:Main"><ZoneTemplate>
  4. Within the pasted lines of code look up the lines starting with
    <ControlMode
    and
    <FormType
    In the "Control mode" tag replace the "Edit" with "New", in the "FormType"-Section replace the digit "6" with "8".
  5. Before saving, you have to generate a new GUID for the pasted control in your NewForm.aspx otherwise your EditForm.aspx will be broken after saving!!!
    There are online GUID generators on the internet so you don't need Visual Studio, e. g.: http://www.somacon.com/p113.php
    Generate a new GUID and asign it to the "__WebPartId" attribute in the very first line of code of your control:
    <WebPartPages:ListFormWebPart runat="server" __MarkupType="xmlmarkup" WebPart="true" __WebPartId="{YOUR_NEW_GUID_HERE}" >
  6. Look up the <ID></ID>-Tag further below (it was about 27 lines below in my case) and change a random number in the ID, e. g.
    Before: <ID>g_f01e99f1_7bcf_4f33_aa97_4b7b471903f4</ID>



    After: <ID>g_19C00971-00EB-4100-856E-CFF701F31723</ID>
  1. Save your work...and your done!  

MORE INFORMATION

If you want to customize the controls that appear on the NewForm.aspx page, and...If you want to customize the controls that appear on the NewForm.aspx page, and if you do not want to show the default List Form Web Part, you can hide the List Form Web Part. To do this, follow these steps:

  1. Start SharePoint Designer 2007, and then open the NewForm.aspx page for the list.
  2. Right-click the List Form Web Part, and then click Web Part Properties.
  3. Expand Layout, click to select the Hidden check box, and then click OK.
http://jpy-tech.com/blog/?tag=/invalid-page-url
joe Smo replied to Anoop S on 27-Sep-11 07:15 AM
Appreciate the response, I have seen these two solutions on a google search, however they seem very risky to me considering the sensitivity of the existing data, and the multiple possibilities of losing the existing list. Does anyone have a new solution by chance?

Thank you

S