<?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: get FamilySymbol from Family Class in Revit API Forum</title>
    <link>https://forums.autodesk.com/t5/revit-api-forum/get-familysymbol-from-family-class/m-p/8608452#M44104</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;yes, these problems - caused by false framework - are not obvious.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Congrats for solving it.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Revitalizer&lt;/P&gt;</description>
    <pubDate>Wed, 20 Feb 2019 13:55:08 GMT</pubDate>
    <dc:creator>Revitalizer</dc:creator>
    <dc:date>2019-02-20T13:55:08Z</dc:date>
    <item>
      <title>get FamilySymbol from Family Class</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/get-familysymbol-from-family-class/m-p/8608132#M44100</link>
      <description>&lt;P&gt;I am new to revit API development.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I want to get Family Symbol from Family. while I was checking in revit API Documentation I found below code&lt;/P&gt;
&lt;PRE&gt;&lt;CODE&gt;&lt;SPAN class="highlight-keyword"&gt;public&lt;/SPAN&gt; &lt;SPAN class="highlight-keyword"&gt;void&lt;/SPAN&gt; GetInfoForSymbols(Family family)
{
    StringBuilder message = &lt;SPAN class="highlight-keyword"&gt;new&lt;/SPAN&gt; StringBuilder(&lt;SPAN class="highlight-literal"&gt;"Selected element's family name is : "&lt;/SPAN&gt; + family.Name);
    ISet&amp;lt;ElementId&amp;gt; familySymbolIds = family.GetFamilySymbolIds();  //ERROR

    &lt;SPAN class="highlight-keyword"&gt;if&lt;/SPAN&gt; (familySymbolIds.Count == &lt;SPAN class="highlight-number"&gt;0&lt;/SPAN&gt;)
    {
        message.AppendLine(&lt;SPAN class="highlight-literal"&gt;"Contains no family symbols."&lt;/SPAN&gt;);
    }
    &lt;SPAN class="highlight-keyword"&gt;else&lt;/SPAN&gt;
    {
        message.AppendLine(&lt;SPAN class="highlight-literal"&gt;"The family symbols contained in this family are : "&lt;/SPAN&gt;);

        &lt;SPAN class="highlight-comment"&gt;// Get family symbols which is contained in this family&lt;/SPAN&gt;
        &lt;SPAN class="highlight-keyword"&gt;foreach&lt;/SPAN&gt; (ElementId id &lt;SPAN class="highlight-keyword"&gt;in&lt;/SPAN&gt; familySymbolIds)
        {
            FamilySymbol familySymbol = family.Document.GetElement(id) &lt;SPAN class="highlight-keyword"&gt;as&lt;/SPAN&gt; FamilySymbol;
            &lt;SPAN class="highlight-comment"&gt;// Get family symbol name&lt;/SPAN&gt;
            message.AppendLine(&lt;SPAN class="highlight-literal"&gt;"\nName: "&lt;/SPAN&gt; + familySymbol.Name);
            &lt;SPAN class="highlight-keyword"&gt;foreach&lt;/SPAN&gt; (ElementId materialId &lt;SPAN class="highlight-keyword"&gt;in&lt;/SPAN&gt; familySymbol.GetMaterialIds(&lt;SPAN class="highlight-keyword"&gt;false&lt;/SPAN&gt;))
            {
                Material material = familySymbol.Document.GetElement(materialId) &lt;SPAN class="highlight-keyword"&gt;as&lt;/SPAN&gt; Material;
                message.AppendLine(&lt;SPAN class="highlight-literal"&gt;"\nMaterial : "&lt;/SPAN&gt; + material.Name);
            }
        }
    }

    TaskDialog.Show(&lt;SPAN class="highlight-literal"&gt;"Revit"&lt;/SPAN&gt;,message.ToString());
}&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;I am getting an error in&amp;nbsp;&lt;CODE&gt;ISet&amp;lt;ElementId&amp;gt; familySymbolIds = family.GetFamilySymbolIds();&lt;/CODE&gt;&lt;/P&gt;
&lt;P&gt;ISet is not defined. Can anybody help me in retrieving symbols from family.&lt;/P&gt;
&lt;P&gt;&lt;CODE&gt; &lt;/CODE&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 20 Feb 2019 11:38:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/get-familysymbol-from-family-class/m-p/8608132#M44100</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-02-20T11:38:30Z</dc:date>
    </item>
    <item>
      <title>Re: get FamilySymbol from Family Class</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/get-familysymbol-from-family-class/m-p/8608156#M44101</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;add&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;using System.Collections.Generic;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Revitalizer&lt;/P&gt;</description>
      <pubDate>Wed, 20 Feb 2019 11:48:57 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/get-familysymbol-from-family-class/m-p/8608156#M44101</guid>
      <dc:creator>Revitalizer</dc:creator>
      <dc:date>2019-02-20T11:48:57Z</dc:date>
    </item>
    <item>
      <title>Re: get FamilySymbol from Family Class</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/get-familysymbol-from-family-class/m-p/8608253#M44102</link>
      <description>&lt;P&gt;I am using generic class "using System.Collections.Generic;" but Still its giving error&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The Suggestion I am getting is:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;class Autodesk.Revit.DB.ElementId&lt;/P&gt;
&lt;P&gt;The ElementId object id used as a unique identification for an element within a single project.&lt;/P&gt;
&lt;P&gt;The type or namespace name 'ISet&amp;lt;&amp;gt;' could not be found(are missing directive or an assembly reference?)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 20 Feb 2019 12:35:39 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/get-familysymbol-from-family-class/m-p/8608253#M44102</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-02-20T12:35:39Z</dc:date>
    </item>
    <item>
      <title>Re: get FamilySymbol from Family Class</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/get-familysymbol-from-family-class/m-p/8608423#M44103</link>
      <description>&lt;P&gt;Got the solution. I was using an older .net framework that's why the error was coming.&lt;/P&gt;
&lt;P&gt;Thanks &lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/1103138"&gt;@Revitalizer&lt;/a&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 20 Feb 2019 13:49:18 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/get-familysymbol-from-family-class/m-p/8608423#M44103</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2019-02-20T13:49:18Z</dc:date>
    </item>
    <item>
      <title>Re: get FamilySymbol from Family Class</title>
      <link>https://forums.autodesk.com/t5/revit-api-forum/get-familysymbol-from-family-class/m-p/8608452#M44104</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;yes, these problems - caused by false framework - are not obvious.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Congrats for solving it.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Revitalizer&lt;/P&gt;</description>
      <pubDate>Wed, 20 Feb 2019 13:55:08 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/revit-api-forum/get-familysymbol-from-family-class/m-p/8608452#M44104</guid>
      <dc:creator>Revitalizer</dc:creator>
      <dc:date>2019-02-20T13:55:08Z</dc:date>
    </item>
  </channel>
</rss>

