I would like to generate InfoPath forms (2010) with managed code and debug the form template with Visual Studio 2012. I have downloaded and installed the Visual Studio Tools for Applications 2012 plus the related SDK. Both are installed, but this is apparently not working since going to code in the InfoPath designer will only bring up the stand-alone VSTA (2005 Visual Studio IDE). Also, in the Visual Studio 2012 IDE there is apparently no project templates for InfoPath.

Perhaps if someone has this working and can get me a simple example I may be able to open the project (preferably with Visual Basic code), but I am having no luck creating my own project. Can anyone offer a sample project, or suggest how I might get this working properly?


I have finally found my own personal resolution to this issue. You need to install Office 2013 and use the InfoPath designer that comes with Office 2013. That with all your other pre req's will allow you to debug in VS2012. I have been trying to get out of the VSTA since it's compiler runs C# 2.0. This has personally enhanced my experience with InfoPath forms and a code behind.

**This is a brain dump now: However I still believe we should just be building application pages and developing the code behind. There are some limitations with VSTA Projects and VS2012 solutions, in the flurry of research I did today I do remember reading that you may only bring in one InfoPath form with a code behind per solution. I however have not verified if that is the case, I will be back in the future to finish updating this post since the amount of documentation on this seems fairly limited. Hope this helped!

I would also like to add that you may need to attach the debugger to the "processes of SharePoint".

  • Thanks for your reply. I eventually called Microsoft Support to resolve this and despite their valiant efforts, I ended up resolving the issue through my own further searching at the time. As you say, Office 2013 ultimately resolves the main issue, but it does not solve every issue. There remains difficulties in deploying as an installable full trust form, working with multiple forms in a single project, and working with version/revision/source control through Visual Studio. Visual Studio 208 provided a superior experience with InfoPath forms. – Casey Jul 23 '15 at 19:03
  • The primary difference being that Visual Studio is no longer the controller of the project as it was with Visual Studio 2008 InfoPath template projects. I now manage multiple forms in a cumbersome way where before a Visual Studio solution managed all related InfoPath forms having each form as a sub-project in the solution. Also, I now save the form template directly to a network share and use my own scripting to register the form on clients for full trust. – Casey Jul 23 '15 at 19:06
  • Previously I could deploy directly from Visual Studio to a Windows Installer Package (.msi) and have the package sent to the network share. The installer would handle the registering of forms on client systems. Finally since the Visual Studio project is not exactly maintained by Visual Studio, but is more of an on the fly project that InfoPath sort of supplies (InfoPath rather than Visual Studio is the starting point), I really struggle with version/revision/source control which is essentially not practical to be managed with Visual Studio integration of the versioning system. – Casey Jul 23 '15 at 19:08
  • I begrudgingly deal with these issues in Visual Studio 2012 and InfoPath 2013 through more manual processes and more limited features, but there are times I would like to go back to Visual Studio 2008 where InfoPath integration was in my mind superior. – Casey Jul 23 '15 at 19:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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