Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
DiscussionsAccessExcelInfoPathOutlookPowerPointPublisherWord
DirectoryUser Groups
Related Topics
Outlook ExpressInternet ExplorerWindowsMS Server ProductsMore Topics ...

MS Office Forum / General MS InfoPath Questions / May 2006

Tip: Looking for answers? Try searching our database.

Data value in the form of a reference in XML

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Partha - 18 Apr 2006 07:14 GMT
Hi,

Is there a way that in the data value for text box control, I can use a
reference to a different attribute value from my secondary data connection
(XML).

Here is an example:
Secondary data source XML - <customer name='Microsoft'></customer>

Data value of a text box -
xdXDocument:GetDOM("Second_XML")/address/@name='Microsoft'

Instead of hardcoded value for the name, I want to use a reference from
different part of the seconday data XML. Like /address/@name=../customer/@name

Is this possible? If so, can somebody help me with some examples ..

Thanks,
Partha.
Adam Harding - 18 Apr 2006 11:34 GMT
Partha, Hi

Yep of course there is.  A little bit complicated but i think i can explain
it step by step.

The problem you have to overcome is to get the form to check the value on
the form againt a column in an XML document, find a match and then report
back the corresponding value of a different column in the XML.  On a rule
however you have only 2 of these steps so what you use is the filter on the
data connection.

Have another invisible textbox on the form thats value is from the XML
source filtered by the value entered in your textbox, this will give you the
functionality you need and your rule just says if textbox1 is not blank set
it's value equal to the invisible textbox.

I hope this achives what you want.

Cheers Adam

> Hi,
>
[quoted text clipped - 15 lines]
> Thanks,
> Partha.
Partha - 02 May 2006 05:35 GMT
Thanks Adam.

I will try your suggestion and let you know. Thanks again for your help.

Thanks,
Partha.

> Partha, Hi
>
[quoted text clipped - 35 lines]
> > Thanks,
> > Partha.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.