<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/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>Conditional Default Values</title><link>http://blogs.msdn.com/infopath/archive/2006/11/27/conditional-default-values.aspx</link><description>Sometimes you want the default value of a field to be dependent upon a condition. However, there isn’t any direct functionality to support IF statements in the default values of fields. Substituting a rule for a default value only gets you so far, as</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>re: Conditional Default Values</title><link>http://blogs.msdn.com/infopath/archive/2006/11/27/conditional-default-values.aspx#1164385</link><pubDate>Tue, 28 Nov 2006 10:23:18 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1164385</guid><dc:creator>DavidAir</dc:creator><description>&lt;p&gt;There could be a third caveat for the first approach: it might cause extra postbacks in browser-enabled form templates (something to be verified). Form performance is always an important consideration for those so sometimes a more cumbersome method could yield fewer postbacks.&lt;/p&gt;
</description></item><item><title>Calculating new, default date and time values</title><link>http://blogs.msdn.com/infopath/archive/2006/11/27/conditional-default-values.aspx#1728085</link><pubDate>Tue, 20 Feb 2007 20:38:42 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1728085</guid><dc:creator>InfoPath Team Blog</dc:creator><description>&lt;p&gt;Similar to performing elapsed time calculations, creating a new date or time value based on a previous&lt;/p&gt;
</description></item><item><title>re: Conditional Default Values</title><link>http://blogs.msdn.com/infopath/archive/2006/11/27/conditional-default-values.aspx#1936843</link><pubDate>Fri, 23 Mar 2007 14:08:10 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1936843</guid><dc:creator>Lixinfeng</dc:creator><description>&lt;p&gt;When the BoolCondition is a bool xml element which can be null, the result of Method 2 will be an empty string.&lt;/p&gt;
&lt;p&gt;To resolved this problem, the condition should be modified like this:&lt;/p&gt;
&lt;p&gt;concat(&lt;/p&gt;
&lt;p&gt;substring(&amp;quot;Yes&amp;quot;, 1, not(not(IsTrue)) * 3), &lt;/p&gt;
&lt;p&gt;substring(&amp;quot;No&amp;quot;, 1, not(IsTrue) * 2)&lt;/p&gt;
&lt;p&gt;)&lt;/p&gt;
&lt;p&gt;The double not() function will convert null value to false, then the result will be right.&lt;/p&gt;
</description></item><item><title>re: Conditional Default Values</title><link>http://blogs.msdn.com/infopath/archive/2006/11/27/conditional-default-values.aspx#4895071</link><pubDate>Thu, 13 Sep 2007 18:01:04 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:4895071</guid><dc:creator>jeff.arrington</dc:creator><description>&lt;p&gt;For selecting the default values this does work as desired, however if the user then changes the field value, it will revert back to the True or false value accordingly. There are no rules applied nor data validation being applied. Why will it not accept the new value and why would it possibly be revering back to resulting default value?&lt;/p&gt;
</description></item><item><title>re: Conditional Default Values</title><link>http://blogs.msdn.com/infopath/archive/2006/11/27/conditional-default-values.aspx#7094690</link><pubDate>Sun, 13 Jan 2008 06:33:36 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:7094690</guid><dc:creator>JasonEley</dc:creator><description>&lt;p&gt;Excellent post. Another caveat to Method 1....the expression is not supported by Form Server (MOSS 2007). The expression in Method 2 is however.&lt;/p&gt;
</description></item><item><title>Calculating Elapsed Time…without code!</title><link>http://blogs.msdn.com/infopath/archive/2006/11/27/conditional-default-values.aspx#8877249</link><pubDate>Tue, 19 Aug 2008 00:23:22 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8877249</guid><dc:creator>InfoPath Team Blog</dc:creator><description>&lt;p&gt;UPDATE: Due to the number of requests for adding more columns to this sample, I have re-designed how&lt;/p&gt;
</description></item><item><title>re: Conditional Default Values</title><link>http://blogs.msdn.com/infopath/archive/2006/11/27/conditional-default-values.aspx#9536410</link><pubDate>Tue, 07 Apr 2009 21:16:28 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9536410</guid><dc:creator>ElenaS</dc:creator><description>&lt;p&gt;Not sure if you can help me, but I am trying to work with a repeating table from a Batch data source and I want the table to automatically populate with values already existing on the form. The problem is that on this repeating table I cannot see on the Design side all the fields in the revolving table...It automatically picks up the field names from the Batch file when I do a preview. &lt;/p&gt;
&lt;p&gt;What i would like to be able to do is say:&lt;/p&gt;
&lt;p&gt;when FieldName=&amp;quot;Title&amp;quot; then FieldValue=Field1&lt;/p&gt;
&lt;p&gt;when FieldName=&amp;quot;FirstName&amp;quot; then FieldValue=Field2&lt;/p&gt;
&lt;p&gt;....&lt;/p&gt;
&lt;p&gt;but it tells me that FieldName (it writes it as @Name) is not a valid field or group (probably because it is not assigned a specific value, it contains 4-5 rows).&lt;/p&gt;
&lt;p&gt;Is there any type of logic I can write to fix this issue?&lt;/p&gt;
&lt;p&gt;Thanks,&lt;/p&gt;
&lt;p&gt;Elena&lt;/p&gt;
</description></item><item><title>re: Conditional Default Values</title><link>http://blogs.msdn.com/infopath/archive/2006/11/27/conditional-default-values.aspx#9536552</link><pubDate>Tue, 07 Apr 2009 22:45:04 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9536552</guid><dc:creator>infopath</dc:creator><description>&lt;p&gt;Hi Elena,&lt;/p&gt;
&lt;p&gt;I provided an answer to this quesstion in the Submitting to a SharePoint list post.&lt;/p&gt;
&lt;p&gt;Scott&lt;/p&gt;
</description></item><item><title>re: Conditional Default Values</title><link>http://blogs.msdn.com/infopath/archive/2006/11/27/conditional-default-values.aspx#9883910</link><pubDate>Tue, 25 Aug 2009 20:37:44 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9883910</guid><dc:creator>Elfoamerican</dc:creator><description>&lt;p&gt;I believe there is also Method 3 in addition to Method 2 where you can do the same but without error prone hardcoding of symbol positions. I have the working example here:&lt;/p&gt;
&lt;p&gt;&lt;a rel="nofollow" target="_new" href="http://alecpojidaev.wordpress.com/2009/07/06/how-to-check-if-your-form-is-dirty/"&gt;http://alecpojidaev.wordpress.com/2009/07/06/how-to-check-if-your-form-is-dirty/&lt;/a&gt;&lt;/p&gt;
</description></item></channel></rss>