<?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>Qdabra qRules</title><link>https://www.infopathdev.com:443/forums/131.aspx</link><description>qRules adds support to your InfoPath  forms. With qRules, you can add features to your form that require code, but without having to write it. </description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Help needed using DateDiff Function multiple times on a single form</title><link>https://www.infopathdev.com:443/forums/thread/74349.aspx</link><pubDate>Fri, 20 Jan 2012 20:34:15 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:74349</guid><dc:creator>Hilary Stoupa</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/74349.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=131&amp;PostID=74349</wfw:commentRss><description>&lt;p&gt;In your rule where you run the date diff function, copy the value of&amp;nbsp;the results node&amp;nbsp;to another field. Then you can run additional commands without worrying about it gettng overwritten.&lt;/p&gt;</description></item><item><title>Help needed using DateDiff Function multiple times on a single form</title><link>https://www.infopathdev.com:443/forums/thread/74347.aspx</link><pubDate>Fri, 20 Jan 2012 20:22:54 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:74347</guid><dc:creator>Durbs</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/74347.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=131&amp;PostID=74347</wfw:commentRss><description>&lt;p&gt;I have a form that has 3 from dates and 3 To dates.&lt;/p&gt;
&lt;p&gt;I have injected the form with QRules and I am using the DateDiff function triggered by a rule on when users enter the To Field to return the amount of days between the Start and End date.&lt;br /&gt;The result of the query returns to the QRules &amp;#39;Result&amp;#39; field which I have put on my form.&lt;br /&gt;Example Start Date 20-01-12 End Date 22-01-12 Results = 2&lt;br /&gt;Code: concat(&amp;quot;DateDiff /date1=&amp;quot;, ., &amp;quot; /date2=&amp;quot;, startdate, &amp;quot; /component=days&amp;quot;)&lt;/p&gt;
&lt;p&gt;Now on the same form I have another field (Not a repeatintg Table) &lt;br /&gt;Trip 2 Start Date (From2)&amp;nbsp;Trip 2 End Date (To2)&lt;br /&gt;Again I use the Date Diff Function obviously this time referenceing the 2nd Start and End Date Fields&lt;br /&gt;Code: concat(&amp;quot;DateDif / date1=&amp;quot;, ., &amp;quot;/date2=&amp;quot;, From2, &amp;quot;/component=days&amp;quot;)&lt;br /&gt;The issue is (And I&amp;#39;m sure its just me not quite understanding how this works) How can I get the query to return the value for the second date to anything other than the QRules &amp;#39;Result&amp;#39; Field and if I can&amp;#39;t do that how do I get the second dates to return another value to the field other than &amp;#39;2&amp;#39; the value from the first&amp;nbsp;query.&lt;/p&gt;
&lt;p&gt;Hope I explained that well enough.&lt;/p&gt;
&lt;p&gt;Appreciate any responses.&amp;nbsp;&lt;/p&gt;</description></item></channel></rss>