How to open infopath templates in code and change data connections URL -


i need iterate through infopath templates (xsn files) , change url of data connections, , save changes templates.

the data connections want change, points lists in sharepoint environment.

so, how accomplish task?

i thinking doing console application.

infopath doesn't make easy deploy different servers. have used powershell script can use console app or scripting language.

steps follow:
1. extract files xsn (either use extrac32 util ms or rename zip , use zip library)
2. change data connection (string replace) in manifest.xsf, template.xml, , sampledata.xml
3. repackage files xsn (either use cabarc util ms or zip , rename)

it pain have entire script less page long , runs pretty fast. 1 caveat ran needed delay between steps 1 , 2 - files weren't finished extracting , script trying change them.


Comments

Popular posts from this blog

c# - how to write client side events functions for the combobox items -

exception - Python, pyPdf OCR error: pyPdf.utils.PdfReadError: EOF marker not found -