How to add resource file (xml) to Form Programmatically - InfoPath Dev
in

InfoPath Dev

How to add resource file (xml) to Form Programmatically

Last post 01-13-2009 03:02 AM by Rajitha. 4 replies.
Page 1 of 1 (5 items)
Sort Posts: Previous Next
  • 01-12-2009 09:21 PM

    How to add resource file (xml) to Form Programmatically

    hi,

    i'm new to IP development

    i designed application form using IP 2007 and it contains customers.xml as resource file, i want to add same file with different data Programmatically before publish

    thanks

  • 01-12-2009 10:10 PM In reply to

    Re: How to add resource file (xml) to Form Programmatically

    We can modify the resource files in infopath itseif.

    1.Open infopath in design mode.
    2.Go to Tools->Resource Files.
    3.Remove the existing customers.xml file and add the latest customers.xml file.
    4.Save the form.

     

     

    Madhuri
    http://www.ggktech.com
  • 01-12-2009 10:24 PM In reply to

    • Anuma
    • Top 25 Contributor
      Female
    • Joined on 07-20-2005
    • India
    • Posts 525

    Re: How to add resource file (xml) to Form Programmatically

    Hi,

    1. Can you verify below steps.

    1. Open form in design mode.
    2. Select Tools à Resource Files.
    3. Click on add button and select your xml file.
    4. Select “Replace the existing file” option.
    5. Click on ok.

    Note: Make sure your new xml file and already added xml file name should be same.

      2. Otherwise extract you template into one folder. Now replace your new “customers.xml” file fin the extracted folder. In this way you will see the newly added values in the infopath form.

    If you want to add any new values, then update your xml file in the extracted folder. It is the better way to update the Resource file from Extracted folder.

    Anuma Chinthapalli /
    http://www.GGKTech.com
  • 01-12-2009 11:20 PM In reply to

    Re: How to add resource file (xml) to Form Programmatically

    i want to do it using c# not using IP UI

  • 01-13-2009 03:02 AM In reply to

    Re: How to add resource file (xml) to Form Programmatically

    Hi,

    If you want to add the same xml file with different data then, no need to change the xml file itself.

    You can change the data in the xml file, right?

    To get xml file in to form code you can use the below statement.

    IXMLDOMDocument2 domCustomers = (IXMLDOMDocument2)thisXDocument.GetDOM("Customers");

    Hope this helps.

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