Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I have a custom list with a custom content type inherited from the Folder content type.

When I insert a new item in the list I do it like this:

newItem["Name"] = "New Folder";
newItem["Content Type"] = "Package";
newItem.Update();

The item is inserted but I found that its title is something like 51_.000 and if I insert another item the title is 52_.000 and so on.

Is there something wrong with this code? If so, how do I insert a folder with the title properly?

share|improve this question
add comment

2 Answers

The Title field is not the same as the Name field. Try updating the Title field to the desired value.

share|improve this answer
    
I already did that and still not working –  Mina Samy Jun 23 '10 at 6:23
add comment

This is because you have the list in something like a Meeting Workspace.

You need to set the list to create Series items first.

This is the setting you need to set for the List. Ensure you do this at creation time, as you cannot undo it.

http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.splist.multipledatalist.aspx

share|improve this answer
    
Sorry but the list is not in a meeting workspace, it is a custom list in a Team site –  Mina Samy Jun 21 '10 at 7:13
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.