<?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: User accessing form</title><link>https://www.infopathdev.com:443/forums/thread/51807.aspx</link><pubDate>Tue, 16 Feb 2010 13:53:16 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:51807</guid><dc:creator>zubair</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/51807.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=51807</wfw:commentRss><description>&lt;p&gt;Here is my solution step by step:&amp;nbsp;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;div&gt;Create a read only view in your form template&lt;/div&gt;&lt;/li&gt;
&lt;li&gt;
&lt;div&gt;Create a field say &amp;#39;UserName&amp;#39; to store the name of the user (or UserID if u like)&lt;/div&gt;&lt;/li&gt;
&lt;li&gt;
&lt;div&gt;At the time of loading (in form loading event) check if the form is not openned by any other user using&amp;nbsp;&amp;#39;this.ReadOnly == false&amp;#39;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/div&gt;&lt;/li&gt;
&lt;li&gt;
&lt;div&gt;If form is not already open&amp;nbsp;i.e &amp;#39;this.ReadOnly == false&amp;#39; :&lt;/div&gt;&lt;/li&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div&gt;Store the name of logged-in user in the&amp;nbsp;&amp;#39;UserName&amp;#39; field in the form loading event &lt;/div&gt;&lt;/li&gt;
&lt;li&gt;
&lt;div&gt;&lt;font face="Verdana"&gt;Switch to normal view using &amp;quot; e.SetDefaultView(&amp;quot;NormalViewName&amp;quot;) &amp;quot;, where NormalViewName is the name of you &amp;quot;Normal&amp;quot; View, &lt;/font&gt;&lt;font face="Arial"&gt;in form loading event&lt;/font&gt;&lt;/div&gt;&lt;/li&gt;
&lt;li&gt;
&lt;div&gt;&lt;font face="Verdana"&gt;In the &amp;quot;OnSwitchView&amp;quot; event use &lt;/font&gt;&amp;#39;this.Save()&amp;#39; to save the form.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;
&lt;li&gt;
&lt;div&gt;If form is already opened by another user:&lt;/div&gt;&lt;/li&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div&gt;Display the message and name of the user working on the form using the &amp;#39;UserName&amp;#39; field&lt;/div&gt;&lt;/li&gt;
&lt;li&gt;
&lt;div&gt;Open the read only view of the form by switching to read only view &lt;font face="Verdana"&gt;using &amp;quot; e.SetDefaultView(&amp;quot;ReadOnlyViewName&amp;quot;) &amp;quot; (where ReadOnlyViewName is the name of you &amp;quot;Read Only&amp;quot; View)&lt;/font&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;&lt;/ol&gt;
&lt;p&gt;I hope this will help.&amp;nbsp;I will wait for your comments and suggestions&amp;nbsp;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Note: we are not using &amp;#39;date updated&amp;#39; field of the form library for tracking changes as it will be updated everytime&amp;nbsp;&amp;#39;this.Save()&amp;#39; statement is executed. Instead changes are tracked from audit log maintained seperately.&lt;/p&gt;</description></item><item><title>Re: User accessing form</title><link>https://www.infopathdev.com:443/forums/thread/51424.aspx</link><pubDate>Fri, 05 Feb 2010 00:54:29 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:51424</guid><dc:creator>zxkuqyb</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/51424.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=51424</wfw:commentRss><description>&lt;p&gt;I&amp;#39;m needing the same answer...does anyone have any insights for Zubair&amp;#39;s question?&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Thanks,&lt;/p&gt;
&lt;p&gt;&amp;nbsp;Tom Barrett&lt;/p&gt;</description></item><item><title>User accessing form</title><link>https://www.infopathdev.com:443/forums/thread/39710.aspx</link><pubDate>Thu, 19 Mar 2009 10:45:06 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:39710</guid><dc:creator>zubair</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/39710.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=39710</wfw:commentRss><description>&lt;p&gt;Hi All, &amp;nbsp;&lt;/p&gt;
&lt;p&gt;I need your help! As you all know, if&amp;nbsp;one user (say User A) opens a form another user (say User B) who tries to access the same form recieves the following message:&lt;/p&gt;
&lt;p&gt;&amp;quot;The form cannot be filled out because you do not have adequate permission, another user has the form open, or the form is open in another program.Do you want to open a read-only copy of the form?&amp;quot;&lt;/p&gt;
&lt;p&gt;Now my question is:&lt;/p&gt;
&lt;p&gt;1. Can I retrieve the name of the user&amp;nbsp; (AD name) who opened the form&amp;nbsp;first (User A)?&lt;/p&gt;
&lt;p&gt;2. Can I make this form editable to User B as well (while another user has the form open)?&lt;/p&gt;
&lt;p&gt;Waiting for reply. Thanks in advance&lt;/p&gt;</description></item></channel></rss>