<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.infopathdev.com:443/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Web Services</title><link>https://www.infopathdev.com:443/forums/48.aspx</link><description> </description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Passing two parameters to a web service and recieving a result back</title><link>https://www.infopathdev.com:443/forums/thread/23878.aspx</link><pubDate>Mon, 22 Oct 2007 01:21:21 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:23878</guid><dc:creator>bwilbourne</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/23878.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=48&amp;PostID=23878</wfw:commentRss><description>&lt;p&gt;Nevermind-I figured it out.&amp;nbsp; I needed to have the NamespaceManager on the last XPathNavigator line.&lt;/p&gt;
&lt;p&gt;Thanks anyway...&lt;/p&gt;</description></item><item><title>Passing two parameters to a web service and recieving a result back</title><link>https://www.infopathdev.com:443/forums/thread/23877.aspx</link><pubDate>Mon, 22 Oct 2007 00:54:41 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:23877</guid><dc:creator>bwilbourne</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/23877.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=48&amp;PostID=23877</wfw:commentRss><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;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.&amp;nbsp; I am using C# managed code in InfoPath 2007.&amp;nbsp; I am not sure what I am missing with this one.&amp;nbsp; I am getting everything up until the Execute statement, then I am not recieving anything back.&amp;nbsp; Any ideas?&amp;nbsp; I have posted my code below:&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Thanks-&lt;/p&gt;&lt;font color="#2b91af" size="2"&gt;XPathNavigator&lt;/font&gt;&lt;font size="2"&gt; _wsNav = &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;this&lt;/font&gt;&lt;font size="2"&gt;.DataSources[&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&amp;quot;NextNumSlctDataCnctn&amp;quot;&lt;/font&gt;&lt;font size="2"&gt;].CreateNavigator();&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; 
&lt;p&gt;&lt;/font&gt;&lt;font color="#2b91af" size="2"&gt;DataConnection&lt;/font&gt;&lt;font size="2"&gt; _getNextNumConn = &lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;this&lt;/font&gt;&lt;font size="2"&gt;.DataConnections[&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&amp;quot;NextNumSlctDataCnctn&amp;quot;&lt;/font&gt;&lt;font size="2"&gt;];&lt;/p&gt;_wsNav.SelectSingleNode(&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&amp;quot;/dfs:myFields/dfs:queryFields/ns1:NextNumSelect/ns1:EnvmtName&amp;quot;&lt;/font&gt;&lt;font size="2"&gt;, NamespaceManager).SetValue(_envtName);&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt;_wsNav.SelectSingleNode(&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&amp;quot;/dfs:myFields/dfs:queryFields/ns1:NextNumSelect/ns1:ApplcName&amp;quot;&lt;/font&gt;&lt;font size="2"&gt;, NamespaceManager).SetValue(_applcName);&lt;/font&gt;&lt;/font&gt;&lt;font size="2"&gt; 
&lt;p&gt;_getNextNumConn.Execute();&lt;/p&gt;
&lt;p&gt;&lt;/font&gt;&lt;font color="#2b91af" size="2"&gt;XPathNavigator&lt;/font&gt;&lt;font size="2"&gt; _wsResultNav = _wsNav.SelectSingleNode(&lt;/font&gt;&lt;font color="#a31515" size="2"&gt;&amp;quot;/dfs:myFields/dfs:dataFields/ns1:NextNumSelectResponse/ns1:NextNumSelectResult/NextNumRsult/dbo.NextNum&amp;quot;&lt;/font&gt;&lt;font size="2"&gt;);&lt;/p&gt;
&lt;p&gt;&lt;/font&gt;&lt;font color="#0000ff" size="2"&gt;string&lt;/font&gt;&lt;font size="2"&gt; _mainresult = &lt;/font&gt;&lt;font color="#2b91af" size="2"&gt;Convert&lt;/font&gt;&lt;font size="2"&gt;.ToString(_wsResultNav);&lt;/p&gt;&lt;/font&gt;</description></item></channel></rss>