Maybe you have wondered what is the difference between the SPWeb.AvailableContentTypes and SPWeb.ContentType, I know I did. Reading intellisence, I couldn’t really tell which one to use, they both seem close to being identical:
I decided to work with SPWeb.AvailableContentTypes but ran into problems when trying to update my content as I was continually getting the "The collection cannot be modified" error.
Turns out that the SPWeb.AvailableContentTypes is a read-only property. Now reading the Remarks section on msdn, you can see that they mention it is a read-only property but I really wished this kind of information would be included in intellisence.