3
votes

I have a custom list definition created via visual studio 2010. I would like to create a calendar view of this list using the web interface. When I attempt to create the view however, I am greeted with a helpful error message of:

Error

Cannot complete this action.

Please try again.

About the problem:

  • When I attempt to duplicate this error while running Fiddler2, I see a response of 404 Not Found when attempting to access /_vti_bin/owssvr.dll?CS=65001 using the HTTP POST verb.

  • No errors are logged in the ULS logs.

  • If I create a new custom list and attempt to reproduce the issue by adding two date columns and creating the calendar view, everything works as expected.

  • The schema.xml file defining the list is fairly large, with close to 25 fields.

  • I am using custom templates for the new, edit, and display forms.

  • I have defined a new custom view showing a subset of the columns in schema.xml

Does anyone know of any "gotchas" or things to look for in my list definition that could be related to this issue at all?

Has anyone encountered this issue before, and know of a way to fix it?

Failing those, what more can I do to debug this?

To avoid overflowing this question with large code blocks, you can view my list definition here:

Elements.xml - http://pastebin.com/97ucAedZ

Schema.xml - http://pastebin.com/2brpMJgT

ListInstance Elements.xml - http://pastebin.com/gnCXVpmh

2
The user account that you used to create the view, has it been deleted and recreated since after SharePoint installation?ukhardy
Nope. I'm not able to create the view, I get the error message after clicking OK on the Create View page, and the view doesn't get created.Kyle Trauberman
Post up the <ListTemplate> node of your custom list, might be something we can spot in there that looks awry.James Love
Do you get the error when you manually create a list & view from your ListTemplate (as opposed to the ListInstance spat out by the Feature)? (Not sure if you already stated that).James Love
@JamesLove If I manually create a list and then create a view on that list, no I do not get the error. If I create a brand new list definition, deploy it, then try to create a view on that, I do not get the errorKyle Trauberman

2 Answers

1
votes

I agree with moontear. I think your Content Type ID is invalid. If you are building off a Custom List template, I would expect your Content Type ID to be:

<ContentType ID="0x0100781A2C74BF4bfd81AE710DB1EACAE745"
                   Name="$Resources:Item"
                   Group="$Resources:List_Content_Types"
                   Description="$Resources:ItemCTDesc"
                   Version="1">

To inherit from Item, you should have 0x01 then 00 followed by a Guid. You have the right number of characters, if you use 00 instead of 70.

For more information, see Content Type IDs.

0
votes

In cases like this, i usually take these steps:

  1. Create List/View manually in MOSS.
    Export list as template and try to
    find out what is wrong in my
    template.
  2. Start with clean template, add one field etc at a time, test, repeat until error emerges.

Your xml seems ok, so i think it will be another MOSS 'gotcha' or 'aha' moment.