Access to secondary Data source with filter and copy data to main data source - InfoPath Dev
in

InfoPath Dev

Access to secondary Data source with filter and copy data to main data source

Last post 02-28-2008 10:27 AM by Clay Fox. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 02-28-2008 02:01 AM

    • pietro
    • Not Ranked
    • Joined on 02-28-2008
    • Posts 1

    Access to secondary Data source with filter and copy data to main data source

    Hi, I'm a newbie in infopath 2007, and I would like to understand how I can solve my problem: I've a product list on a secondary data source, based on a xml file.

    Secondary file (products) is like this :

    <Prodotti>

    <Prodotto>

    <ChiavePDV></ChiavePDV>

    <CTV>15PF4121/01</CTV>

    <FamilyType>LCD</FamilyType>

    <Description>15" LCD Flat TV</Description>

    <Brand>PHILIPS</Brand>

    <PrezzoSuggerito>100.44</PrezzoSuggerito>

    <Prezzo xsi:nil="true"></Prezzo>

    <Quantita></Quantita>

    </Prodotto>

    ......

    </Prodotti>

    I'm expected to save my template with some info reported on the main DS, all the information reported on the secondary file, plus the two info Prezzo and Quantità that have to be added on the form from the user.

    The product list may be very long, so we decide to have it as a 2 ^ DS external to the template to be able to add products to the xml file easily.

    The user has to see all the product list on the form, to add all the info required

     

    So, my problem are:

    1) I would like to filter all the data shown to the user on the Family Type field: I thought to define a field on the form, a drop down list box, whose list box entries are looked up from external data source (products).

    2) I would like to have a table on the form reporting the product list that has to be completed (filtered on the family type choosen): how can I do it?

    a) Can I define a table on the form, and the table directly refer to the secondary data source? (with the table field taken from the 2^ DS?)

    b) Or I'm to define a table on the form, with fields defined on the main form, and I create a rule on field defined on the form, the drop down list box, to fill all the fields componing the table? It works only for the first row of the table.

    3) Would it be a good idea to copy the secondary data source data on the primary on the loading form event and working on the primary fields?

    Other ideas?

    Thanks for your support.

    Pietro

     

     

  • 02-28-2008 10:27 AM In reply to

    Re: Access to secondary Data source with filter and copy data to main data source

    Hi Pietro, Welcome to the forum.

    Let me give a few pointers.

    1.  Typically you would have the dropdown display the family types

    2.  Then on your repeating table displaying the product list would have conditional formatting to hide where family type does not equal the selection

    3.  Typically the user would build their personal list by inserting rows and selecting product data to fill each.  You may use code to preinsert rows too.

    Depending on the complexity of the data and how many records you have will impact performance.

    For larger applications you would want to uae a database and web services. This allows you to interface with other systems and provide reporting across all of your form data.

     

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