Auto populatae field - InfoPath Dev
in

InfoPath Dev

Auto populatae field

Last post 09-25-2006 12:57 PM by Matt Faus. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 09-21-2006 12:39 PM

    Auto populatae field

    I am working on a form created using 'New from Data Connection....'.
    Main data connnection is named 'main'.

    In the form I have a field named 'Service_Type_id'which is from main data connection. I change it to a
    dropdown box whose data is binding to the secondary data connection based on the table 'type_desc'

    Here is tbls design in my main data connection
    id
    service_type_id (example: 1,2,3,4)
    comments

    secondary data connection table 'type_desc
    service_type_id
    desc

    I want automatically populate a comments filed in the form based on
    a specfic service_type_id user select from the dropdown box.
    For example, when user selects service_type_id = 4, the comments filed is visible to user.
    Can someone help me out on this question? Thanks in advance!
  • 09-22-2006 03:00 AM In reply to

    • Shiva
    • Top 25 Contributor
    • Joined on 04-15-2005
    • India
    • Posts 694
    Hi,

    You can set Rule on dropdown field and using “Filter Data” option. For example setting value path like:

    xdXDocument:GetDOM("SecondaryDOMName")/my:myFields/.. /my: comment[/my:service_type_id = xdXDocument:get-DOM()/my:myFields/my:service_type_id]
  • 09-22-2006 12:16 PM In reply to

    Thanks for your reply.
    Here, I still get couple questions which make me confused when I tried your solutions.
    When I goto dropdown box property->click rules: do I need to set condition here?
    Click Add Action, select Set A Field's Value from the action drop-down list,
    When I click the Xpath button to the right of Field. Which data source(main or secondary) and field I should select?
    I also click the formula button to the right of Value, click Insert Field Or Group. Which data source(main or secondary) and field I should select?
  • 09-25-2006 12:57 PM In reply to

    Matt Faus / Microsoft InfoPath MVP
    Qdabra® Software / Streamline data gathering to turn process into knowledge
Page 1 of 1 (4 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.