<?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>InfoPath 2010</title><link>https://www.infopathdev.com:443/forums/142.aspx</link><description>Are you exploring new features coming up in 2010? Share information and ask questions here!</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Different behaviors with InfoPath 2010 preview and published SharePoint 2010 form</title><link>https://www.infopathdev.com:443/forums/thread/66084.aspx</link><pubDate>Wed, 20 Apr 2011 21:32:52 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:66084</guid><dc:creator>ptutcher</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/66084.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=142&amp;PostID=66084</wfw:commentRss><description>&lt;p&gt;I have created a calculated field using the following XPath statement that will create a semi-colon seperated list based on selected values in a multiple selection list box. The data that is stored in the multiple selection&amp;nbsp; list box are IDs, so I perform a lookup in a seperate data feed to pull in human readable titles. &lt;/p&gt;
&lt;p&gt;It works perfectly in InfoPath preview mode, but fails to function when published to SharePoint 2010 (gets an empty list, no errors).&lt;/p&gt;
&lt;p&gt;After further investigation I have narrowed the issue down to the &lt;strong&gt;current()&lt;/strong&gt; function within the statement. If I replace &lt;strong&gt;current()&lt;/strong&gt; with a value of &lt;strong&gt;1&lt;/strong&gt; I get a repeating list of a single title.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Is there another why to reference the current value within the nested eval statements without using &lt;strong&gt;current()&lt;/strong&gt;?&lt;/p&gt;
&lt;p&gt;&lt;span style="FONT-SIZE:10pt;FONT-FAMILY:&amp;#39;Arial&amp;#39;,&amp;#39;sans-serif&amp;#39;;"&gt;xdMath:Eval(xdMath:Eval(dfs:dataFields/my:SharePointListItem_RW/my:Related_x0020_To/Value, &amp;#39;concat(substring(xdXDocument:GetDOM(&amp;quot;Technology Platform Temp&amp;quot;)/dfs:myFields/dfs:dataFields/d:SharePointListItem_RW/d:Title[../d:ID = current()], 1, (count(../Value) = 2 or ../Value[last()] = current()) * string-length(xdXDocument:GetDOM(&amp;quot;Technology Platform Temp&amp;quot;)/dfs:myFields/dfs:dataFields/d:SharePointListItem_RW/d:Title[../d:ID = current()])), substring(concat(xdXDocument:GetDOM(&amp;quot;Technology Platform Temp&amp;quot;)/dfs:myFields/dfs:dataFields/d:SharePointListItem_RW/d:Title[../d:ID = current()], &amp;quot;; &amp;quot;), 1, ((count(../Value) &amp;gt; 2 and ../Value[last()] != current()) * (string-length(current()) &amp;gt; 0)) * string-length(concat(xdXDocument:GetDOM(&amp;quot;Technology Platform Temp&amp;quot;)/dfs:myFields/dfs:dataFields/d:SharePointListItem_RW/d:Title[../d:ID = current()], &amp;quot;; &amp;quot;))))&amp;#39;), &amp;quot;..&amp;quot;)&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="FONT-SIZE:10pt;FONT-FAMILY:&amp;#39;Arial&amp;#39;,&amp;#39;sans-serif&amp;#39;;"&gt;&amp;nbsp;Any help would be much appreciated!&lt;/span&gt;&lt;/p&gt;</description></item></channel></rss>