Passing two parameters to a web service and recieving a result back - InfoPath Dev
in

InfoPath Dev

Passing two parameters to a web service and recieving a result back

Last post 10-21-2007 06:21 PM by bwilbourne. 1 replies.
Page 1 of 1 (2 items)
Sort Posts: Previous Next
  • 10-21-2007 05:54 PM

    Passing two parameters to a web service and recieving a result back

    Hello,

     I have a data connection that is a web service that I need to pass two parameters to and then recieve a value back from the webservice.  I am using C# managed code in InfoPath 2007.  I am not sure what I am missing with this one.  I am getting everything up until the Execute statement, then I am not recieving anything back.  Any ideas?  I have posted my code below:

     Thanks-

    XPathNavigator _wsNav = this.DataSources["NextNumSlctDataCnctn"].CreateNavigator();

    DataConnection _getNextNumConn = this.DataConnections["NextNumSlctDataCnctn"];

    _wsNav.SelectSingleNode("/dfs:myFields/dfs:queryFields/ns1:NextNumSelect/ns1:EnvmtName", NamespaceManager).SetValue(_envtName);_wsNav.SelectSingleNode("/dfs:myFields/dfs:queryFields/ns1:NextNumSelect/ns1:ApplcName", NamespaceManager).SetValue(_applcName);

    _getNextNumConn.Execute();

    XPathNavigator _wsResultNav = _wsNav.SelectSingleNode("/dfs:myFields/dfs:dataFields/ns1:NextNumSelectResponse/ns1:NextNumSelectResult/NextNumRsult/dbo.NextNum");

    string _mainresult = Convert.ToString(_wsResultNav);

  • 10-21-2007 06:21 PM In reply to

    Re: Passing two parameters to a web service and recieving a result back

    Nevermind-I figured it out.  I needed to have the NamespaceManager on the last XPathNavigator line.

    Thanks anyway...

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