Results 1 to 3 of 3

Thread: Access to Compound Structure in roofs and ceilings

  1. #1
    Member
    Join Date
    2018-03
    Posts
    3
    Login to Give a bone
    0

    Default Access to Compound Structure in roofs and ceilings

    I try to access the layers of walls, floors, ceilings and roofs, but I only allow it in walls and floors, not in ceilings and roofs.
    How could you access your layers and their materials?
    Thank you for your answers!


    Code:
    CompoundStructure Construccion = null;
    
                
                if (btnMUROS.Checked == true)
                {
                    Wall Muro = seleccionado as Wall;
                    Construccion = Muro.WallType.GetCompoundStructure();
                }
                if (btnSUELOS.Checked == true)
                {
                    Floor Suelo = seleccionado as Floor;
                    Construccion = Suelo.FloorType.GetCompoundStructure();
    
                }
                if (btnCUBIERTAS.Checked == true)
                {
                    RoofType Cubierta = seleccionado as RoofType;
                }
                if (btnTECHOS.Checked == true)
                {
                    CeilingType TipoTecho = seleccionado as CeilingType;
    
                }
    
    
                int NumeroCapas = Construccion.LayerCount;
                //txtConstruccion.Text=Construccion.StructuralMaterialIndex.ToString();
                IList<CompoundStructureLayer> ListaCapas = Construccion.GetLayers();
                string LINEA = "Numero de capas = " + NumeroCapas + Environment.NewLine + "EXTERIOR";

  2. #2
    Active Member
    Join Date
    2011-11
    Location
    Saint-Omer, Pas-de-Calais, France
    Posts
    58
    Login to Give a bone
    0

    Default Re: Access to Compound Structure in roofs and ceilings

    Why don't you cast your seleccionado variable to RoofBase, then access the RoofType property like you do for the floor?

    For the ceiling, there is no CeilingType property, I think you have to use the GetTypeId() method to get the element type which should be a CeilingType object.
    Manager and software developer
    WIIP
    http://wiip.fr

  3. #3
    Member
    Join Date
    2018-03
    Posts
    3
    Login to Give a bone
    0

    Default Re: Access to Compound Structure in roofs and ceilings

    Thank you! Your answer has helped me a lot!

    I attach the code so you can serve others in the future


    Code:
    if (btnSUELOS.Checked == true)
                    {
                        Floor Suelo = seleccionado as Floor;
                        Construccion = Suelo.FloorType.GetCompoundStructure();
    
                    }
                    if (btnCUBIERTAS.Checked == true)
                    {
                        RoofBase Cubierta = seleccionado as RoofBase;
                        Construccion = Cubierta.RoofType.GetCompoundStructure();
                        
                    }
                    if (btnTECHOS.Checked == true)
                    {
                        CeilingType TECHO = _doc.GetElement(IDDELTIPO) as CeilingType;
                        Construccion = TECHO.GetCompoundStructure();
    
                        
                    }

Similar Threads

  1. 2012: Roofs, Floors, and Ceilings
    By StacyJennifer in forum Revit Architecture - General
    Replies: 1
    Last Post: 2011-12-21, 06:06 PM
  2. GBXML to HAP, Ceilings read as Roofs!
    By jkhmiller in forum Revit MEP - General
    Replies: 1
    Last Post: 2009-03-03, 05:52 PM
  3. Attaching Ceilings to Roofs
    By dimitri in forum Revit Architecture - General
    Replies: 6
    Last Post: 2008-12-15, 02:26 PM
  4. Rendered Compound Ceilings
    By kevinv in forum Revit - Rendering
    Replies: 3
    Last Post: 2006-01-21, 06:07 AM
  5. Compound floors or roofs
    By agd in forum Revit Architecture - General
    Replies: 7
    Last Post: 2005-04-12, 02:26 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •