I am missing something obvious. I want to return the name of an Imported (not linked) DWG. The following is just not doing it for me...
foreach (ImportInstance ii in new FilteredElementCollector(pDoc)
.OfClass(typeof(ImportInstance))
.Cast<ImportInstance>()
.Where(i => i.IsLinked == false))
{
ElementId Id = ii.Id;
string name = ii.Name;
string tname = ii.GetType().Name;
Solved! Go to Solution.
Solved by DavidIntVeld. Go to Solution.
Have you tried the
ii.Category.Name property?
That returns the name in my application...
The day is made when you learn one new thing...
Many thanks, Dale
Hello
There is way to get the path file
example:
c:\structural\sheet\102-floor 1 plant.dwg
and change path
c:\mep\structural\sheet\102-floor 1 plant.dwg
regards