InfoPath with C# code, it just doesn't work. - InfoPath Dev

InfoPath Dev

Use our Google Custom Search for best site search results.

InfoPath with C# code, it just doesn't work.

Last post 07-08-2013 11:21 AM by Jimmy. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 07-03-2013 09:11 AM

    InfoPath with C# code, it just doesn't work.

    Good day,

    I've got a quite simple Document Information Panel view, created in InfoPath 2013, to be used in Word. I need to perform a calculation on one of the fields. It's too complicated to perform this calculation within InfoPath, I need to write some code in C# of VB (using Visual Studio). That shouldn't be any problem since InfoPath has a Developer tab with Visual Studio integration. The thing is, it just doesn't work. Even when I just click on "On After Change event" button and Visual Studio generates an empty function for me, it already produces an error when using the form. Because I didn't add any code yet, it's 100% sure the error is not as result of my custom code.

    It's even weirder. When I create a new empty form, just add a button, and add a skeleton code (an empty function), it won't work. It just gives a generic code. Is there anything else then just saving what I have to change to be able to use an InfoPath form with code? Or is there some security setting I should change on my computer, or within InfoPath?

    The error message is: "Document Information Panel cannot open a new form.
    The form cannot be opened. To fix this problem, contact the form designer.
    Form template:
    Document Information Panel cannot open the selected form because of an error in the form's code.
    Error in the application."

    I hope I gave enough information. If anything is missing, please ask. Thank you very much,

    Meneer Aart.
  • 07-08-2013 11:21 AM In reply to

    Re: InfoPath with C# code, it just doesn't work.

    I haven't worked with Document Information Panels, but one thing to verify here is that is in your local intranet sites in the Internet Explorer security settings. I believe I have seen this error result from not having the publish site in IE's local intranet sites.

    Jimmy Rishe / Software Developer / Microsoft MVP
    Qdabra Software
Page 1 of 1 (2 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.