How to populate a dropdown with a WS in C# - InfoPath Dev
in

InfoPath Dev

How to populate a dropdown with a WS in C#

Last post 06-22-2005 11:49 PM by Coita Thierry. 4 replies.
Page 1 of 1 (5 items)
Sort Posts: Previous Next
  • 06-14-2005 08:02 AM

    How to populate a dropdown with a WS in C#

    Hi,


    I have make a webservice I can make a call with the managed code C# and I have a return !
    no more probleme with that! I'm happy

    But now I have my result in a XMLDocumenthow I can populate my dropdown listebox in my infopath form?


    Thanks for your help
    It's very appreciated

    Thierry

    Every moment hesitated is a moment gone for life!!! Think about it
    Infopath 2007, Langage: C#2.0 (Modèle Objet 2003)
    merci de lire ceci
  • 06-16-2005 03:19 PM In reply to

    Re: How to populate a dropdown with a WS in C#

    Hello Virgul,
    I'm not sure if i fully understood the issue so let me put it my own words and you can correct me if i have it wrong.

    You have a data connection to a Webservice. This is a Recieve data connection and you get data from the Web service that you now want to use to populate a dropdown in the UI?

    To do this in the Dropdown properties you need to select the third option "Look up values in a data connection to a database ....", choose the appropriate data conection and then map the Entries, Value and Display ame to the data that you want to see in the dropdown.

    Hope this helps!

    Shanthi
    InfoPathDev India
    Shanthi Reddy
  • 06-21-2005 07:31 AM In reply to

    Re: How to populate a dropdown with a WS in C#

    Ok thanks for your answer and sorry for my late reply!

    What I want to do is on a button click:

    Call a webservice with C# not with infopath design mode! I am ok for That!

    receive an answer and catch him! ok

    Now I have a XMLDocument that contain the value of what I whant in my Dropdown listebox:

    <text>
    <content>Marcel</content>
    <content>Henry</content>
    <content>Bernard</content>
    </text>

    Now how to do (with a C# code) for put this my listebox (location: /my:Case/my:Name)?

    I hope you understand!

    Thanks a lot for your help!

    ++

    Thierry
    Infopath 2007, Langage: C#2.0 (Modèle Objet 2003)
    merci de lire ceci
  • 06-21-2005 12:35 PM In reply to

    Re: How to populate a dropdown with a WS in C#

    Hi,
    You need to copy this XMLDocument to a dataconecction which is actually binded to the dropdown in the designer.

    So you need to maintain a secondary data connection which binds to the dropdown and you need to Copy the data to that dataconnection with help of c#/Managed code.

    There are some posts in this forum about how to copy data into a dataconnection with the help of c# code.

    Hope this Helps!

    Agni
    InfoPathDev India
  • 06-22-2005 11:49 PM In reply to

    Re: How to populate a dropdown with a WS in C#

    Hi,

    Thanks a lot !

    It's very strange that you can directly populate the primary database with the XMLDocument! But it's like this!

    ++

    Thierry

    Every moment hesitated is a moment gone for life!!! Think about it
    Infopath 2007, Langage: C#2.0 (Modèle Objet 2003)
    merci de lire ceci
Page 1 of 1 (5 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.