<?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: Programmatically changing the default view of an InfoPath form (on Load) via VB</title><link>https://www.infopathdev.com:443/forums/thread/86160.aspx</link><pubDate>Thu, 17 Jan 2013 17:29:16 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:86160</guid><dc:creator>ZtBoy</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/86160.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=86160</wfw:commentRss><description>How would you accomplish this using InfoPath 2010 and VB OnLoad?

Thanks!</description></item><item><title>Re: Programmatically changing the default view of an InfoPath form (on Load) via VB</title><link>https://www.infopathdev.com:443/forums/thread/40488.aspx</link><pubDate>Thu, 09 Apr 2009 16:05:07 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:40488</guid><dc:creator>tavalanche</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/40488.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=40488</wfw:commentRss><description>&lt;p&gt;Thanx Hilary!!!&amp;nbsp; You&amp;#39;re &lt;em&gt;&lt;u&gt;great&lt;/u&gt;&lt;/em&gt;; you really are...&lt;/p&gt;
&lt;p&gt;That&amp;#39;s &lt;em&gt;exactly&lt;/em&gt; what I needed!&amp;nbsp; &lt;/p&gt;
&lt;p&gt;&amp;nbsp;You have a nice one..!&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;- Tav&lt;/p&gt;</description></item><item><title>Re: Programmatically changing the default view of an InfoPath form (on Load) via VB</title><link>https://www.infopathdev.com:443/forums/thread/40462.aspx</link><pubDate>Wed, 08 Apr 2009 22:54:45 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:40462</guid><dc:creator>Hilary Stoupa</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/40462.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=40462</wfw:commentRss><description>&lt;p&gt;Hi:&lt;/p&gt;
&lt;p&gt;Are you using VB.NET? InfoPath 2007 would be, in the loading event for the form:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;e.SetDefaultView(&lt;font color="#a31515" size="2"&gt;&amp;quot;View2&amp;quot;&lt;/font&gt;) &lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;With View2 replaced with the name of your view. InfoPath 2003 would be, in the onload event for the form: &lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;e.XDocument.ViewInfos(&lt;font color="#a31515" size="2"&gt;&amp;quot;View2&amp;quot;&lt;/font&gt;).ISDEFAULT=&lt;font color="#0000ff" size="2"&gt;True&lt;/font&gt;&lt;/p&gt;&lt;/blockquote&gt;</description></item><item><title>Programmatically changing the default view of an InfoPath form (on Load) via VB</title><link>https://www.infopathdev.com:443/forums/thread/40459.aspx</link><pubDate>Wed, 08 Apr 2009 20:44:06 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:40459</guid><dc:creator>tavalanche</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/40459.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=40459</wfw:commentRss><description>&lt;p&gt;Guys,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;How would I programmatically change the default view of an InfoPath form (on Load) via VB?&amp;nbsp; I&amp;#39;ve found the following code snippets:&lt;/p&gt;
&lt;p&gt;&lt;font style="FONT-SIZE:7.5pt;" color="#333399"&gt;&lt;strong&gt;BLOCKED SCRIPT&lt;br /&gt;&lt;/strong&gt;&lt;/font&gt;&lt;font style="FONT-SIZE:10pt;" face="Courier New" color="#333399"&gt;XDocument.ViewInfos(&amp;quot;My View Name&amp;quot;).IsDefault = true;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font style="FONT-SIZE:7.5pt;" color="#333399"&gt;&lt;strong&gt;C#:&lt;br /&gt;&lt;/strong&gt;&lt;/font&gt;&lt;font style="FONT-SIZE:10pt;" face="Courier New" color="#333399"&gt;thisXDocument.ViewInfos[&amp;quot;My View Name&amp;quot;].IsDefault = true;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;...but none of them refer to the VB code that does this.&amp;nbsp; Any help would be GREATLY appreciated.&amp;nbsp; Thanx-so-much..!&lt;/p&gt;
&lt;p&gt;&amp;nbsp;- Tav&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item></channel></rss>