<?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>Newbie Questions</title><link>https://www.infopathdev.com:443/forums/39.aspx</link><description>New to InfoPath? Search to see if your question has already been answered. If it has not, then ask it here or the appropriate topic forum.</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Conditional default values -- how can this be accomplished.</title><link>https://www.infopathdev.com:443/forums/thread/33426.aspx</link><pubDate>Thu, 23 Oct 2008 16:19:30 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:33426</guid><dc:creator>Jimmy</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/33426.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=33426</wfw:commentRss><description>&lt;p&gt;That solution is close, but I don&amp;#39;t think it will work too consistently.&amp;nbsp; To see what I mean:&lt;/p&gt;
&lt;p&gt;Preview the form.&lt;/p&gt;
&lt;p&gt;Enter &amp;quot;aaa&amp;quot; in field1.&amp;nbsp; Text field&amp;#39;s value changes to &amp;quot;aaa&amp;quot; (expected)&lt;br /&gt;Enter &amp;quot;bbb&amp;quot; in field2.&amp;nbsp; Text field&amp;#39;s value remains as &amp;quot;aaa&amp;quot; (expected)&lt;br /&gt;Delete contents of field1.&amp;nbsp; &lt;em&gt;Text field&amp;#39;s value remains as &amp;quot;aaa&amp;quot; (unexpected)&lt;br /&gt;&lt;/em&gt;Change contents of field2 to &amp;quot;bbbb&amp;quot;.&amp;nbsp;Text field&amp;#39;s value changes to &amp;quot;bbbb&amp;quot; (expected)&lt;br /&gt;Enter &amp;quot;aaa&amp;quot; in field1. &lt;em&gt;Text field&amp;#39;s value remains as &amp;quot;bbbb&amp;quot; (unexpected)&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;The italicized parts show where the behavior is inconsistent.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;To accomplish what you described in the original post, add the following rules to both field1 and field2 (it should be exactly the same two rules for both fields):&lt;br /&gt;Rule 1 - Condition: field1 [is blank]&amp;nbsp; Action: set Text field to value of field2&amp;nbsp;&amp;nbsp; (when field1 is blank, the text field&amp;#39;s value is the value of field2)&lt;br /&gt;Rule 2 - Condition: field1 [is not blank]&amp;nbsp; Action: set Text field to value of field1&amp;nbsp; (when field1 is not blank, the text field&amp;#39;s value is the value of field1)&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Conditional default values -- how can this be accomplished.</title><link>https://www.infopathdev.com:443/forums/thread/33423.aspx</link><pubDate>Thu, 23 Oct 2008 15:29:04 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:33423</guid><dc:creator>Ed Rodman</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/33423.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=33423</wfw:commentRss><description>&lt;p&gt;Anuma,&amp;nbsp;&lt;/p&gt;
&lt;p&gt;It worked....Thank you so much.&lt;/p&gt;
&lt;p&gt;Very strange code. How did you figure this out? &lt;/p&gt;
&lt;p&gt;Sensational,. Thanks again.&amp;nbsp;&amp;nbsp;&amp;nbsp; Ed&lt;/p&gt;</description></item><item><title>Re: Conditional default values -- how can this be accomplished.</title><link>https://www.infopathdev.com:443/forums/thread/33420.aspx</link><pubDate>Thu, 23 Oct 2008 14:42:11 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:33420</guid><dc:creator>Anuma</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/33420.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=33420</wfw:commentRss><description>&lt;p class="MsoNormal" style="MARGIN:0in 0in 0pt;"&gt;&lt;font face="Times New Roman" size="3"&gt;Hi,&lt;/font&gt;&lt;/p&gt;&lt;font face="Times New Roman" size="3"&gt;&amp;nbsp;&lt;/font&gt; 
&lt;p class="MsoNormal" style="MARGIN:0in 0in 0pt;"&gt;&lt;font face="Times New Roman" size="3"&gt;Add following Rule to first field:&lt;/font&gt;&lt;/p&gt;
&lt;ol style="MARGIN-TOP:0in;"&gt;
&lt;li class="MsoNormal" style="MARGIN:0in 0in 0pt;mso-list:l0 level1 lfo1;tab-stops:list .5in;"&gt;&lt;font face="Times New Roman" size="3"&gt;Open Fields1 properties and select Rules.&lt;/font&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="MARGIN:0in 0in 0pt;mso-list:l0 level1 lfo1;tab-stops:list .5in;"&gt;&lt;font face="Times New Roman" size="3"&gt;Select “Set Condition”.&lt;/font&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="MARGIN:0in 0in 0pt;mso-list:l0 level1 lfo1;tab-stops:list .5in;"&gt;&lt;font face="Times New Roman" size="3"&gt;Select Expression in first dropdown and paste following formula in second text box.&lt;/font&gt;&lt;/li&gt;&lt;/ol&gt;
&lt;p class="MsoNormal" style="MARGIN:0in 0in 0pt 0.25in;"&gt;&lt;font face="Times New Roman" size="3"&gt;“. != &amp;quot;&amp;quot; and ../my:field2 = &amp;quot;&amp;quot;”&lt;/font&gt;&lt;/p&gt;
&lt;ol style="MARGIN-TOP:0in;" start="4"&gt;
&lt;li class="MsoNormal" style="MARGIN:0in 0in 0pt;mso-list:l0 level1 lfo1;tab-stops:list .5in;"&gt;&lt;font face="Times New Roman" size="3"&gt;click on ok.&lt;/font&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="MARGIN:0in 0in 0pt;mso-list:l0 level1 lfo1;tab-stops:list .5in;"&gt;&lt;font face="Times New Roman" size="3"&gt;Select add action and select “Set Fields value”.&lt;/font&gt;&lt;/li&gt;
&lt;li class="MsoNormal" style="MARGIN:0in 0in 0pt;mso-list:l0 level1 lfo1;tab-stops:list .5in;"&gt;&lt;font face="Times New Roman" size="3"&gt;Select “Text Field” in second field text box and “Field1” in value text box.&lt;/font&gt;&lt;/li&gt;&lt;/ol&gt;&lt;font face="Times New Roman" size="3"&gt;&amp;nbsp;Follow the same steps to &amp;quot;Field2&amp;quot;. But replace field 1 with field2 and field with field1.&lt;/font&gt;&lt;font face="Times New Roman" size="3"&gt;&lt;/font&gt;&amp;nbsp;</description></item><item><title>Conditional default values -- how can this be accomplished.</title><link>https://www.infopathdev.com:443/forums/thread/33417.aspx</link><pubDate>Thu, 23 Oct 2008 14:24:45 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:33417</guid><dc:creator>Ed Rodman</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/33417.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=33417</wfw:commentRss><description>&lt;p&gt;I have a text field that I want to set with a default value, the default value will be one of two fields depending if they are filled in....how can I accomplish this. Its a conditional default value.&amp;nbsp; IF field1 is blank, field2, else field1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ................ How can this be done in a text field.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;thanks much&lt;/p&gt;</description></item></channel></rss>