A topic that is not particularly well document with SharePoint is how to deploy a web browser compatible InfoPath form via a feature.
Deploying a form through the Central Administration site provides such a form. This isn’t much use if you want to make the package that you ship to a client installable without involving some manual steps.
Installing and registering an InfoPath form, along with a custom content type is pretty straight forward once you know the required steps.
Start by creating a content type that inherits from the Forms type. The following is a sample content type’s markup.
Since I’ve been developing with Visual Studio 2010 for SP I can’t help but feel I’ve wasted valuable time trying to resolve issues that the caching mechanism used by Visual Studio has caused.
For example, I deployed a feature that created a list on the activating web using the ListInstance element. Initially, I set the name and description with hard coded values and all was good in the world.
I then added a feature resource and added entries for the list instance’s name and description. Deleting the list and re-deploying the solution (via Visual Studio) gave the desired result. I then decided to change the display title of the list and updated the resource file accordingly.