Ejemplo n.º 1
0
        public static cSapModel GetModel()
        {
            ETABS2016.cOAPI     ETABSObject = (ETABS2016.cOAPI)Marshal.GetActiveObject("CSI.ETABS.API.ETABSObject");
            ETABS2016.cSapModel EtabsModel  = ETABSObject.SapModel;

            return(EtabsModel);
        }
Ejemplo n.º 2
0
        //     internal class SectionProp
        //    {

        //    }

        //    internal class Frame
        //   {
        //      internal Line line { get; set; }

        //     internal SectionProp sectionprop { get; set; }



        //  }



        public static bool StartETABS(bool Run)
        {
            ETABS2016.cOAPI   etabs;
            ETABS2016.cHelper hlp = new ETABS2016.Helper();
            etabs = NewMethod(hlp);
            long r;

            r = etabs.ApplicationStart();
            ETABS2016.cSapModel model = etabs.SapModel;
            r = model.InitializeNewModel(eUnits.kN_m_C);
            r = model.File.NewBlank();

            return(true);
        }
Ejemplo n.º 3
0
        public static Frame From_Line(Line line, string sectionprop, int rotation)
        {
            ETABS2016.cOAPI   etabs;
            ETABS2016.cHelper hlp = new ETABS2016.Helper();
            etabs = hlp.GetObject("CSI.ETABS.API.ETABSObject");
            long r;

            ETABS2016.cSapModel model = etabs.SapModel;


            Frame nfrm = new Frame();

            nfrm.line        = line;
            nfrm.sectionprop = sectionprop;
            nfrm.rotation    = rotation;

            Point i = nfrm.line.StartPoint;
            Point j = nfrm.line.EndPoint;

            double xi = i.X;
            double yi = i.Y;
            double zi = i.Z;

            double xj = j.X;
            double yj = j.Y;
            double zj = j.Z;

            string Name = "1";

            r = model.FrameObj.AddByCoord(xi, yi, zi, xj, yj, zj, ref Name);

            nfrm.label = Name;


            return(nfrm);
        }