Switching to Coding in C# - InfoPath Dev
in

InfoPath Dev

Switching to Coding in C#

Last post 06-15-2006 06:14 AM by janicethorne. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 06-14-2006 02:01 PM

    Switching to Coding in C#

    I have a form that I had developed and subsequently added some code to. I didn't realize when I added the code (I do not have a heavy background in programming)that it was c#. The form code was saved as a javascript file. I subsequently purchased and installed Visual Studio 2005 and the Infopath toolkit, but I can't seem to modify this code in anything but js. In addition, I can't modify any code in the form with C# - it all defaults to js. Is there something I am missing? Even when I open the project in C# there does not seem to be a way to change the js extension. Any help is appreciated.
  • 06-14-2006 02:12 PM In reply to

    Re: Switching to Coding in C#

    Unfortunately, you will have to manually rewrite all of your code into the .cs files. If you start a new InfoPath project and import your old template as the template that is used in the project, then the old .js file will still be there, but it won't be doing anything. What you could do is copy the code from the .js file and then translate line-by-line into the .cs file.

    I hope this helps, let us know if you have any more questions!
    Matt Faus / Microsoft InfoPath MVP
    Qdabra® Software / Streamline data gathering to turn process into knowledge
  • 06-15-2006 06:14 AM In reply to

    Re: Switching to Coding in C#

    Matt:

    Thank you for your help. However, manually rewriting the code is not the problem - there is not much code there and I would be happy to move it over. I just don't know how to get to a cs file. The form code always opens in a js format and the code is C#. How do I get around that? Do I need to open the form in Visual Studio? When I do that though, I still get the js file. I have even deleted the code out of all of the buttons and it does no good.

    Rather than do it this way, is there code available that is javascript that will accomplish what I am trying to do? All I need to do is to program each of three buttons to submit to a different email address so the form can be routed as it is completed.

    Thank you again.

Page 1 of 1 (3 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.