How to pass values to InfoPath while loading?

K

Karthik

We are using InfoPath forms to fill out user information. This form needs to
be populated with some values while loading. For this we need to send a
parameter value to InfoPath while loading. Is there any standard way to send
parameters while the form is loading in InfoPath?
 
P

pleasehelp

i am doing something similar. i am writing the user's information to an xml
file, and than in infopath reference the xml file as a secondary data source
(tools-->secondary data sources), and in the onload script read the xml file
using XDocument.DataObjects.

i am curious as to if there are other (better) ways to do this.
 
G

G. Tarazi

There is a bit easier way



What I am doing is having a minimum xml (that has the parameters) and
regular xml.



Now there is a web page that is writing the minimum xml to IE with the
processing instructions, infopath opens, and then loads data from the
secondary data source, using the parameters in the minimum xml.



Then using the xml replace functions, I am coping the xml from the secondary
data source to the primary data source, and the form is loaded and ready to
run.



It was not easy at the beginning; it did take me time until I understood the
xml schema better, then changing it in a way to make InfoPath not to
complain when the minimum xml is provided, and tons of other problems.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top