<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Restrict to open same window multiple times in autocad and inventor in .NET Forum</title>
    <link>https://forums.autodesk.com/t5/net-forum/restrict-to-open-same-window-multiple-times-in-autocad-and/m-p/8495321#M23899</link>
    <description>&lt;P&gt;How to restrict to open same window multiple times in autocad and inventor?&lt;/P&gt;
&lt;P&gt;The scenario is when any window in autocad or inventor is opened then if we again try to open the same window then it will get opened and multiple same window get displayed.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So i want to restrict to open a window if the window is already opened.&lt;/P&gt;
&lt;P&gt;Is there any solution for this?&lt;/P&gt;
&lt;P&gt;Here is the code to open a window.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="code to open a window" style="width: 999px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/586327iEE1AABE01E852FD8/image-size/large?v=v2&amp;amp;px=999" role="button" title="multiplewindow.png" alt="code to open a window" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;code to open a window&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 02 Jan 2019 08:35:10 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2019-01-02T08:35:10Z</dc:date>
    <item>
      <title>Restrict to open same window multiple times in autocad and inventor</title>
      <link>https://forums.autodesk.com/t5/net-forum/restrict-to-open-same-window-multiple-times-in-autocad-and/m-p/8495321#M23899</link>
      <description>&lt;P&gt;How to restrict to open same window multiple times in autocad and inventor?&lt;/P&gt;
&lt;P&gt;The scenario is when any window in autocad or inventor is opened then if we again try to open the same window then it will get opened and multiple same window get displayed.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So i want to restrict to open a window if the window is already opened.&lt;/P&gt;
&lt;P&gt;Is there any solution for this?&lt;/P&gt;
&lt;P&gt;Here is the code to open a window.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="code to open a window" style="width: 999px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/586327iEE1AABE01E852FD8/image-size/large?v=v2&amp;amp;px=999" role="button" title="multiplewindow.png" alt="code to open a window" /&gt;&lt;span class="lia-inline-image-caption" onclick="event.preventDefault();"&gt;code to open a window&lt;/span&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Jan 2019 08:35:10 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/restrict-to-open-same-window-multiple-times-in-autocad-and/m-p/8495321#M23899</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-01-02T08:35:10Z</dc:date>
    </item>
    <item>
      <title>Re: Restrict to open same window multiple times in autocad and inventor</title>
      <link>https://forums.autodesk.com/t5/net-forum/restrict-to-open-same-window-multiple-times-in-autocad-and/m-p/8495335#M23900</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You should either use a modal dialog or, if you need a modelss UI, use a &lt;A href="https://forums.autodesk.com/t5/net/set-new-paletteset-quot-mypalette-quot-guid-newguid-bug/m-p/8482735/highlight/true#M61071" target="_blank"&gt;PaletteSet&lt;/A&gt;.&lt;/P&gt;</description>
      <pubDate>Wed, 02 Jan 2019 08:55:34 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/restrict-to-open-same-window-multiple-times-in-autocad-and/m-p/8495335#M23900</guid>
      <dc:creator>_gile</dc:creator>
      <dc:date>2019-01-02T08:55:34Z</dc:date>
    </item>
    <item>
      <title>Re: Restrict to open same window multiple times in autocad and inventor</title>
      <link>https://forums.autodesk.com/t5/net-forum/restrict-to-open-same-window-multiple-times-in-autocad-and/m-p/8495404#M23901</link>
      <description>&lt;P&gt;Something like this?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;            // check if another window of the same type is already open
            foreach (System.Windows.Forms.Form f in System.Windows.Forms.Application.OpenForms)
            {
                if (f is frmBatchManager)
                {
                    if (f.WindowState != System.Windows.Forms.FormWindowState.Normal) f.WindowState = System.Windows.Forms.FormWindowState.Normal;

                    f.BringToFront();
                    return;
                }
            }

            // Not found, open a new modeless window
            frmBatchManager dlg = new frmBatchManager();
            Application.ShowModelessDialog(dlg);&lt;/PRE&gt;</description>
      <pubDate>Wed, 02 Jan 2019 09:56:25 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/restrict-to-open-same-window-multiple-times-in-autocad-and/m-p/8495404#M23901</guid>
      <dc:creator>m.cicognani</dc:creator>
      <dc:date>2019-01-02T09:56:25Z</dc:date>
    </item>
  </channel>
</rss>

