<?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 Re: Retrieving the file path of nested CAD files in Revit API Forum</title>
    <link>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6531364#M63314</link>
    <description>&lt;P&gt;The Revit API does not enable you to dive into the internals of a DWG.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can use the AutoCAD.NET API to achieve that.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can easily use&amp;nbsp;&lt;SPAN&gt;the AutoCAD.NET API from within your Revit add-in, provided you have both AutoCAD and Revit installed.&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 30 Aug 2016 14:59:04 GMT</pubDate>
    <dc:creator>jeremytammik</dc:creator>
    <dc:date>2016-08-30T14:59:04Z</dc:date>
    <item>
      <title>Retrieving the file path of nested CAD files</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6531034#M63313</link>
      <description>&lt;P&gt;in Revit 2016, I can get the list of the CAD files attached (in this instance, AutoCAD) and their path using something like&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;Select Case extRef.ExternalFileReferenceType
	Case ExternalFileReferenceType.CADLink
		dim filepath as string = ModelPathUtils.ConvertModelPathToUserVisiblePath(extRef.GetAbsolutePath)

	Case ....	&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;However, in the case this CAD file has xRefs/Images (images which by the way are not displayed in Revit), I only get the file path of the 'master'.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;does anybody have any idea how I can also find the list of the the master's xRefs (and their path) as well, as, if they exists, their nested xRefs ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Aug 2016 12:50:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6531034#M63313</guid>
      <dc:creator>btmsoftware</dc:creator>
      <dc:date>2016-08-30T12:50:33Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving the file path of nested CAD files</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6531364#M63314</link>
      <description>&lt;P&gt;The Revit API does not enable you to dive into the internals of a DWG.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can use the AutoCAD.NET API to achieve that.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You can easily use&amp;nbsp;&lt;SPAN&gt;the AutoCAD.NET API from within your Revit add-in, provided you have both AutoCAD and Revit installed.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Aug 2016 14:59:04 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6531364#M63314</guid>
      <dc:creator>jeremytammik</dc:creator>
      <dc:date>2016-08-30T14:59:04Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving the file path of nested CAD files</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6531386#M63315</link>
      <description>&lt;P&gt;As usual, thanx Jeremy for the quick answer...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Yes I could however, that would mean that AutoCAD MUST be installed on the machines running Revit too, which on my dev/test environment is the case.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Actually, if it a requirement to be able to links an AutoCAD file in a Revit project to have AutoCAD on the machine ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Since Revit itself does it (the nested xRefs are indeed displayed), that means that Revit itself can do it, therefore ,next question:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What would it take to convince Autodesk to include that feature in the API in a next SP/Release ? And whom should I get in touch with ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 30 Aug 2016 15:05:36 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6531386#M63315</guid>
      <dc:creator>btmsoftware</dc:creator>
      <dc:date>2016-08-30T15:05:36Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving the file path of nested CAD files</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6597595#M63316</link>
      <description>&lt;P&gt;Hi Jeremy,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Sorry for the delay before responding, got side tracked &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I can get the list of the CAD Links and the file name therefore, indeed, I could use AutoCAD and MicroStation to get their nested references but then, would you know if there's anything (couldn't find anything) to find out if the link is an AutoCAD or a Microstation file ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;the reason is that if it's an AutoCAD file, I don't want to waste time starting up MicroStation and vice-versa....&lt;/P&gt;</description>
      <pubDate>Mon, 03 Oct 2016 07:22:12 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6597595#M63316</guid>
      <dc:creator>btmsoftware</dc:creator>
      <dc:date>2016-10-03T07:22:12Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving the file path of nested CAD files</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6597600#M63317</link>
      <description>&lt;P&gt;Nope, sorry.&lt;/P&gt;</description>
      <pubDate>Mon, 03 Oct 2016 07:24:46 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6597600#M63317</guid>
      <dc:creator>jeremytammik</dc:creator>
      <dc:date>2016-10-03T07:24:46Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving the file path of nested CAD files</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6598033#M63318</link>
      <description>&lt;P&gt;Isn't .DGN or .DWG part of the returned filename?&lt;/P&gt;</description>
      <pubDate>Mon, 03 Oct 2016 13:06:06 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6598033#M63318</guid>
      <dc:creator>Dale.Bartlett</dc:creator>
      <dc:date>2016-10-03T13:06:06Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving the file path of nested CAD files</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6598043#M63319</link>
      <description>&lt;P&gt;yes, if you use the default extension but who's to say that it will be the case on every machine, for every customer....&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have often seen at customer sites that they use an extension for the masters and another for the xRefs so they can visually see in windows&amp;nbsp;Explorer what kind of file it is (I'm not saying it's the right way to go&amp;nbsp;but it's one way.... )&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As a rule of the thumb, I never depend on the extension of a file to determine what it is. For example, .DOC is used by a big lot of software and it would be a big mistake to assume it's Microsoft Word.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 03 Oct 2016 13:10:41 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/retrieving-the-file-path-of-nested-cad-files/m-p/6598043#M63319</guid>
      <dc:creator>btmsoftware</dc:creator>
      <dc:date>2016-10-03T13:10:41Z</dc:date>
    </item>
  </channel>
</rss>

