none
InfoPath code behind project gets created in Temp folder and connection to code lost when form is closed. RRS feed

  • Question

  • My InfoPath 2007 form has code behind and I am upgrading it to InfoPath 2010. I opened the form using InfoPath 2013 updated data connections, changed compatibility to web browser 2010. I clicked on Remove Code and created a new project added all the code to this new project using VS2012(3.5 framework). My code has web references.

    The path for csproj in Programming tab is C:\Users\XXX\Documents\InfoPath Projects\XXX\XXX.csproj. But when I right click on project in Visual Studio and open in explorer, the project resides in C:\Users\XX\AppData\Local\Temp\Vsta\InfoPath\ folder. 

    The code gets compiled, the form works when published and deployed to the server.

    But once I close the form, reopen it and click on developer it says- System Path is not specified. I copied the code from temp to a local folder and tried to give the .csproj path, even then i get the same error. Also, once I close the form the solution folder created in temp get deleted. So every time i want to make a changes to my form should i repeat these steps of adding code and building?



    • Edited by MS283 Wednesday, May 15, 2019 5:45 PM
    Wednesday, May 15, 2019 12:42 PM

All replies

  • Hi MS283,

    Yes, every time you make the changes in the code, you should repeat the steps as you said.

    Best regards,

    Sara Fan


    Please remember to mark the replies as answers if they helped. If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.

    SharePoint Server 2019 has been released, you can click here to download it.
    Click here to learn new features. Visit the dedicated forum to share, explore and talk to experts about SharePoint Server 2019.

    Thursday, May 16, 2019 9:08 AM
    Moderator
  • Thanks for the response. After number of trails, I noticed that the steps of attaching the code must be repeated every time if the compatibility is set as InfoPath browser 2010 in InfoPath Designer 2013 and using VS 2012 (3.5 target framework).

    The connection to the code is not lost  if I set the compatibility as Web Browser(2013) and add code in VS 2012 (4.5 target framework).

    On reopening the form, when i clicked on Developer->Code Editor and can see VS 2012 opening the code.  

    I do not see 'System Path is not specified' error anymore.

    Thursday, May 16, 2019 12:05 PM

  • Hi MS283,

    If the issue is resolved, you could mark the helpful reply as answer. Thank you for your sharing and understanding.


    Best regards,

    Sara Fan


    Please remember to mark the replies as answers if they helped. If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.

    SharePoint Server 2019 has been released, you can click here to download it.
    Click here to learn new features. Visit the dedicated forum to share, explore and talk to experts about SharePoint Server 2019.


    Friday, May 17, 2019 8:44 AM
    Moderator