<?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 Active window name in Revit API Forum</title>
    <link>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3659274#M80332</link>
    <description>&lt;P&gt;Hi everybody!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;whats the best way (in c#) to get the active window name? (for example the name of the drawing window, the name of the main app window, etc...)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;if possible without using the windows api..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thank you&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;best regards&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Frigo&lt;/P&gt;</description>
    <pubDate>Mon, 15 Oct 2012 09:03:50 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2012-10-15T09:03:50Z</dc:date>
    <item>
      <title>Active window name</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3659274#M80332</link>
      <description>&lt;P&gt;Hi everybody!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;whats the best way (in c#) to get the active window name? (for example the name of the drawing window, the name of the main app window, etc...)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;if possible without using the windows api..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thank you&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;best regards&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Frigo&lt;/P&gt;</description>
      <pubDate>Mon, 15 Oct 2012 09:03:50 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3659274#M80332</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2012-10-15T09:03:50Z</dc:date>
    </item>
    <item>
      <title>Re: Active window name</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3670184#M80333</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hi&amp;nbsp;&lt;SPAN&gt;Frigo,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Are your talking about Revit? And want to get the Revit's active view's name and Revit main frame name?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;The simplest way to get the active Revit view name is:&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;View class name + ": " + view name + " - " + ProjectName.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;For example:&amp;nbsp;Floor Plan: 2 - Mech - Project1&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;STRONG&gt;Floor Plan&lt;/STRONG&gt; is the view class name.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;STRONG&gt;Project1&lt;/STRONG&gt; is the project name.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;The active view name can be easily get by : doc.ActiveView.Name property.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;With regard to get the Revit's main app name, there is no straightforward Revit APi can be used. You need to resort to the windows API, I think.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Oct 2012 10:47:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3670184#M80333</guid>
      <dc:creator>Joe.Ye</dc:creator>
      <dc:date>2012-10-23T10:47:02Z</dc:date>
    </item>
    <item>
      <title>Re: Active window name</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3671604#M80334</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;if talking about the main window, the title displayed consists also of product type and year, which can be got by Application.VersionName and Application.VersionNumber.&lt;/P&gt;&lt;P&gt;Window title may change to a shorter string if window is resized.&lt;/P&gt;&lt;P&gt;Also, in a zero-document state, title looks like "[Recent files]", but this depends on Revit's current language.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Revitalizer&lt;/P&gt;</description>
      <pubDate>Wed, 24 Oct 2012 07:28:20 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3671604#M80334</guid>
      <dc:creator>Revitalizer</dc:creator>
      <dc:date>2012-10-24T07:28:20Z</dc:date>
    </item>
    <item>
      <title>Re: Active window name</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3677762#M80335</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Hi&amp;nbsp;&lt;SPAN&gt;Revitalizer,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Good idea to compose the caption string. Normally this should work fine to get the correct string.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;However there are situations the caption is different. For example, the Revit used by the ADN partners, there is a sub-string &amp;nbsp;"Not for resale version" in the caption string, the other parts are the same. There maybe some other situations, for example , the Revit education version.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Cheers,&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 29 Oct 2012 16:13:19 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3677762#M80335</guid>
      <dc:creator>Joe.Ye</dc:creator>
      <dc:date>2012-10-29T16:13:19Z</dc:date>
    </item>
    <item>
      <title>Re: Active window name</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3678658#M80336</link>
      <description>&lt;P&gt;Hi joe.ye,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;yes, I know that there are special strings for special versions.&lt;/P&gt;&lt;P&gt;Also, these strings are localized (as the "[Recent files]" string is).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;After all, I think there is no possibility to get the main window title string except using Windows API functions.&lt;/P&gt;&lt;P&gt;I do not see why not to do so, by the way.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;Revitalizer&lt;/P&gt;</description>
      <pubDate>Tue, 30 Oct 2012 07:58:09 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3678658#M80336</guid>
      <dc:creator>Revitalizer</dc:creator>
      <dc:date>2012-10-30T07:58:09Z</dc:date>
    </item>
    <item>
      <title>Re: Active window name</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3678746#M80337</link>
      <description>&lt;P&gt;Hi all, what about this:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;System.Diagnostics.Process.GetCurrentProcess().MainWindowTitle&lt;/P&gt;&lt;P&gt;I haven't tested this, but maybe it may help you.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;Revitalizer&lt;/P&gt;</description>
      <pubDate>Tue, 30 Oct 2012 09:35:19 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3678746#M80337</guid>
      <dc:creator>Revitalizer</dc:creator>
      <dc:date>2012-10-30T09:35:19Z</dc:date>
    </item>
    <item>
      <title>Re: Active window name</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3682220#M80338</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Cool, I confirmed the result is correct.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 01 Nov 2012 10:21:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/active-window-name/m-p/3682220#M80338</guid>
      <dc:creator>Joe.Ye</dc:creator>
      <dc:date>2012-11-01T10:21:49Z</dc:date>
    </item>
  </channel>
</rss>

