示例#1
0
        public void didBuildModel()
        {
            SwApp.NewPart();
            _swModel = SwApp.IActiveDoc2;
            _swPart  = (PartDoc)(_swModel);

            _swModel.Extension.SelectByID2("Top", "PLANE", 0, 0, 0, false, 0, null, 0);
            _swModel.SketchManager.InsertSketch(true);
            _swModel.ClearSelection2(true);

            _swModel.SketchManager.CreateCornerRectangle(0, 0, 0, Length, Width, 0);
            _swModel.ClearSelection2(true);

            _swModel.SketchManager.InsertSketch(true);

            _swModel.FeatureManager.FeatureExtrusion2(true, false, false, 0, 0, Height, 0.01, false, false, false, false, 1.74532925199433E-02, 1.74532925199433E-02, false, false, false, false, true, true, true, 0, 0, false);

            _swModel.Extension.SelectByID2("", "FACE", Length / 2, Height, -Width / 2, false, 0, null, 0);
            _swModel.ShowNamedView2("*Top", 5);

            _swModel.ViewZoomTo2(-1.40224455089843E-02, 7.79877043000974E-02, 0, 0.090572328390715, -1.30337019942975E-02, 0);

            _swModel.SketchManager.CreateCircle(0.004, Width - 0.004, 0, 0.004, Width - 0.004 + 0.00135, 0);
            _swModel.ClearSelection2(true);

            _swModel.SketchManager.CreateCircle(0.004, 0.004, 0, 0.004, 0.00535, 0);
            _swModel.ClearSelection2(true);

            _swModel.SketchManager.CreateCircle(Length - 0.004, Width - 0.004, 0, Length - 0.004, Width - 0.004 + 0.00135, 0);
            _swModel.ClearSelection2(true);

            _swModel.SketchManager.CreateCircle(Length - 0.004, 0.004, 0, Length - 0.004, 0.00535, 0);
            _swModel.ClearSelection2(true);

            _swModel.ShowNamedView2("*Isometry", 7);

            _swModel.Extension.SelectByID2("Arc1@", "EXTSKETCHSEGMENT", 5.96034675525732E-03, 6.63356185593879E-02, 0, false, 0, null, 0);
            _swModel.FeatureManager.FeatureCut3(true, false, false, 1, 0, 0.005, 0.005, false, false, false, false, 1.74532925199433E-02, 1.74532925199433E-02, false, false, false, false, false, true, true, true, true, false, 0, 0, false);

            _swModel.ViewZoomTo2(-1.30039690871637E-02, 3.75387366394858E-02, 1.58777579102132E-02, 0.142076690355558, -0.052121832944159, 1.58777579102138E-02);
            _swModel.ShowNamedView2("*Left", 3);
            _swModel.ViewZoomTo2(-0.083498837770881115, 0.014433467968860341, -0.060000000000000081, 0.0096740082936823124, -0.016165167848730275, -0.059999999999999866);
            _swModel.Extension.SelectByID2("", "EDGE", 0, Height / 2, 0, true, 0, null, 0);
            _swModel.Extension.SelectByID2("", "EDGE", 0, Height / 2, -Width, true, 0, null, 0);
            _swModel.ShowNamedView2("*Righr", 4);
            _swModel.ViewZoomTo2(-0.013345844591793166, 0.018717276983323025, 0.059999999999999894, 0.080438974189122076, -0.017083126923257995, 0.060000000000000143);
            _swModel.Extension.SelectByID2("", "EDGE", Length, Height / 2, 0, true, 0, null, 0);
            _swModel.Extension.SelectByID2("", "EDGE", Length, Height / 2, -Width, true, 0, null, 0);
            _swModel.ShowNamedView2("*Isometry", 7);
            _swModel.FeatureManager.InsertFeatureChamfer(4, 1, 0.0027, 0.78539816339745, 0, 0, 0, 0);


            _swModel.Extension.SelectByID2("Body-Feature1", "BODYFEATURE", 0, 0, 0, false, 0, null, 0);
            _swModel.Extension.SelectByID2("Unknown", "BROWSERITEM", 0, 0, 0, false, 0, null, 0);
            _swModel.ClearSelection2(true);
            _swPart.SetMaterialPropertyName2("По умолчанию", @"C:/ProgramData/SolidWorks/SolidWorks 2012/Sustainability/Sustainability Extras.sldmat", "Плата системы питания");
            _swModel.ClearSelection2(true);

            _swModel.SaveAs3(@"C:\Certificate\plata.SLDPRT", 0, 2);
        }
示例#2
0
        public void Main()
        {
            List <DispatchWrapper> swObjects = new List <DispatchWrapper>();

            IModelDoc2 model = swApp.IActiveDoc2;

            if (model != null)
            {
                ISelectionMgr selMgr = model.ISelectionManager;

                for (int i = 0; i < selMgr.GetSelectedObjectCount2(-1); i++)
                {
                    object swSelObj = selMgr.GetSelectedObject6(i + 1, -1);
                    swObjects.Add(new DispatchWrapper(swSelObj));//it is required to wrap dispatch pointers to allow selection of objects of different types (i.e. faces, annotations, components etc.) together
                }

                model.ClearSelection2(true);

                Debugger.Break();

                model.Extension.MultiSelect2(swObjects.ToArray(), false, null);
            }
            else
            {
                swApp.SendMsgToUser("Please open the model");
            }
        }
        /// <summary>
        ///     Очистить выделения
        /// </summary>
        public void ClearSelection()
        {
            if (!IsConnectedToApp)
            {
                return;
            }

            _document.ClearSelection2(true);
        }
示例#4
0
 /// <summary>
 /// Clear the selection the manager
 /// </summary>
 public void ClearSelection() => _doc.ClearSelection2(true);
示例#5
0
        /// <summary>
        /// Add componect to active doc
        /// </summary>
        void AddComponectToActiveDoc(string partFileName)
        {
            ModelDocExtension swDocExt;
            AssemblyDoc       swAssy;
            string            tmpPath;
            ModelDoc2         tmpObj;
            bool          boolstat;
            Component2    swcomponent;
            Feature       matefeature;
            string        MateName;
            string        FirstSelection;
            string        SecondSelection;
            swMateAlign_e Alignment;
            string        strCompName;
            string        AssemblyTitle;
            string        AssemblyName;
            int           errors   = 0;
            int           warnings = 0;
            int           mateError;

            // Get title of assembly document
            AssemblyTitle = pDoc.GetTitle();

            // Split the title into two strings using the period (.) as the delimiter
            string[] strings = AssemblyTitle.Split(new Char[] { '.' });

            // Use AssemblyName when mating the component with the assembly
            AssemblyName = (string)strings[0];


            boolstat = true;

            string strCompModelname = null;

            strCompModelname = partFileName;

            // Because the component resides in the same folder as the assembly, get
            // the assembly's path, strip out the assembly filename, concatenate
            // the rest of the path to the component filename, and use this string to
            // open the component
            tmpPath = pDoc.GetPathName();
            //int idx;
            //idx = tmpPath.LastIndexOf(AssemblyTitle);
            string compPath;

            //tmpPath = tmpPath.Substring(0, (idx));
            //compPath = string.Concat(tmpPath, strCompModelname);
            compPath = strCompModelname;

            // Open the component
            tmpObj = (ModelDoc2)swApp.OpenDoc6(compPath, (int)swDocumentTypes_e.swDocPART, 0, "", ref errors, ref warnings);

            // Check to see if the file is read-only or cannot be found; display error
            // messages if either
            if (warnings == (int)swFileLoadWarning_e.swFileLoadWarning_ReadOnly)
            {
                MessageBox.Show("This file is read-only.");
                boolstat = false;
            }

            if (tmpObj == null)
            {
                MessageBox.Show("Cannot locate the file.");
                boolstat = false;
            }

            //Re-activate the assembly so that you can add the component to it
            pDoc   = (ModelDoc2)swApp.ActivateDoc2(AssemblyTitle, true, ref errors);
            swAssy = (AssemblyDoc)pDoc;


            // Add the component to the assembly document.
            // Currently only one option,
            // swAddComponentConfigOptions_e.swAddComponentConfigOptions_CurrentSelectedConfig,
            // works for adding a part using AddComponent5

            // The other options,
            // swAddComponentConfigOptions_e.swAddComponentConfigOptions_NewConfigWithAllReferenceModels
            // and swAddComponentConfigOptions_e.swAddComponentConfigOptions_NewConfigWithAsmStructure,
            // work only for adding assemblies using AddComponent5
            swcomponent = (Component2)swAssy.AddComponent5(strCompModelname, (int)swAddComponentConfigOptions_e.swAddComponentConfigOptions_CurrentSelectedConfig, "", false, "", -1, -1, -1);

            // Get the name of the component for the mate
            strCompName = swcomponent.Name2;

            // Create the name of the mate and the names of the planes to use for the mate
            MateName        = "top_coinc_" + strCompName;
            FirstSelection  = "Top@" + strCompName + "@" + AssemblyName;
            SecondSelection = "Front@" + AssemblyName;
            swDocExt        = (ModelDocExtension)pDoc.Extension;
            pDoc.ClearSelection2(true);

            // Select the planes for the mate
            boolstat = swDocExt.SelectByID2(FirstSelection, "PLANE", 0, 0, 0, true, 1, null, (int)swSelectOption_e.swSelectOptionDefault);
            boolstat = swDocExt.SelectByID2(SecondSelection, "PLANE", 0, 0, 0, true, 1, null, (int)swSelectOption_e.swSelectOptionDefault);

            // Add the mate
            matefeature = (Feature)swAssy.AddMate3((int)swMateType_e.swMateCOINCIDENT, (int)swMateAlign_e.swMateAlignALIGNED, false, 0, 0, 0, 0, 0, 0, 0,
                                                   0, false, out mateError);
            matefeature.Name = MateName;

            pDoc.ViewZoomtofit2();
        }
示例#6
0
 /// <summary>
 /// Снятие всех "меток"
 /// </summary>
 public void RemoveAllocations()
 {
     _model.ClearSelection2(true);
 }
示例#7
0
        private void Button1_Click(object sender, EventArgs e)
        {
            swApp         = new SldWorks();
            swApp.Visible = true;
            swApp.NewPart();
            swModel = swApp.IActiveDoc2;

            swModel.Extension.SelectByID2("Справа", "PLANE", 0, 0, 0, false, 0, null, 0);
            swModel.SketchManager.InsertSketch(true);

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(-0, 0.004, 0, -0, 0.006, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(-0, 0.006, 0, 0.01, 0.006, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.01, 0.006, 0, 0.01, 0.011, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.01, 0.011, 0, 0.015, 0.011, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.015, 0.011, 0, 0.015, 0.0065, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.015, 0.0065, 0, 0.02, 0.0065, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.02, 0.0065, 0, 0.026, 0.005, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.026, 0.005, 0, 0.028, 0.0065, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.028, 0.0065, 0, 0.034, 0.005, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.034, 0.005, 0, 0.036, 0.0065, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.036, 0.0065, 0, 0.042, 0.005, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.042, 0.005, 0, 0.044, 0.0065, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.044, 0.0065, 0, 0.05, 0.005, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.05, 0.005, 0, 0.05, 0.004, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.05, 0.004, 0, 0, 0.004, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(-0, 0.004, 0, 0.05, 0.004, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateCenterLine(-0, 0, 0, 0.05, 0, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();
            swModel.SketchManager.InsertSketch(true);

            // swModel.Extension.SelectByID2("Line17@Эскиз1", "EXTSKETCHSEGMENT", 0, 9.94238977252735E-02, 0.105960140100876, false, 16, null, 0);
            // swModel.Extension.SelectByID2("Эскиз1", "SKETCH", -2.66009057248503E-03, 3.07631837781458E-03, -1.74442594135417E-02, true, 2, null, 0);
            swModel.SelectionManager.EnableContourSelection = true;
            swModel.Extension.SelectByID2("Эскиз1", "SKETCHREGION", -2.66009057248503E-03, 3.07631837781458E-03, -1.74442594135417E-02, true, 2, null, 0);

            swModel.FeatureManager.FeatureRevolve2(true, true, false, false, false, false, 0, 0, 6.2831853071796, 0, false, false, 0.01, 0.01, 0, 0, 0, true, true, true);
            swModel.SelectionManager.EnableContourSelection = false;


            swModel.Extension.SelectByID2("Спереди", "PLANE", 0, 0, 0, false, 0, null, 0);
            swModel.SketchManager.InsertSketch(true);

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateCircle(0, 0, 0, -0.012, -0, 0);

            swModel.SketchManager.CreatePolygon(0, 0, 0, -0.011, 0, 0, 6, true);
            // swModel.SketchAddConstraints("sgFIXED");
            // swModel.SetPickMode();
            swModel.ClearSelection2(true);
            swModel.SketchManager.InsertSketch(true);


            swModel.FeatureManager.FeatureCut4(true, false, false, 0, 0, 0.1, 0.01, false, false, false, false, 1.74532925199433E-02, 1.74532925199433E-02, false, false, false, false, false, true, true, true, true, false, 0, 0, false, false);
            // swModel.SelectionManager.EnableContourSelection = false;



            swModel.Extension.SelectByID2("Справа", "PLANE", 0, 0, 0, false, 0, null, 0);
            swModel.SketchManager.InsertSketch(true);

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.014, 0.011, 0, 0.015, 0.011, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.015, 0.011, 0, 0.015, 0.009526, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.ClearSelection2(true);
            swModel.SketchManager.CreateLine(0.015, 0.009526, 0, 0.014, 0.011, 0);
            swModel.SketchAddConstraints("sgFIXED");
            swModel.SetPickMode();

            swModel.SketchManager.InsertSketch(true);


            swModel.Extension.SelectByID2("Line17@Эскиз1", "EXTSKETCHSEGMENT", 1.91276838961301E-02, 0, 0, true, 0, null, 0);
            swModel.Extension.SelectByID2("Эскиз3", "SKETCHREGION", 3.39317975691915E-03, 1.13603218378812E-02, -1.59961262883416E-02, true, 0, null, 0);
            swModel.ClearSelection2(true);
            swModel.Extension.SelectByID2("Line17@Эскиз1", "EXTSKETCHSEGMENT", 1.91276838961301E-02, 0, 0, false, 16, null, 0);
            swModel.Extension.SelectByID2("Эскиз3", "SKETCH", 3.39317975691915E-03, 1.13603218378812E-02, -1.59961262883416E-02, true, 2, null, 0);
            swModel.SelectionManager.EnableContourSelection = true;
            swModel.Extension.SelectByID2("Эскиз3", "SKETCHREGION", 3.39317975691915E-03, 1.13603218378812E-02, -1.59961262883416E-02, true, 2, null, 0);

            swModel.FeatureManager.FeatureRevolve2(true, true, false, true, false, false, 0, 0, 6.2831853071796, 0, false, false, 0.01, 0.01, 0, 0, 0, true, true, true);
            swModel.SelectionManager.EnableContourSelection = false;
        }
示例#8
0
        private void buttonBuildDetail_Click(object sender, EventArgs e)
        {
            //что с буллстатусом делать


            bool boolstatus = false;


            //выбор плоскости/эскиза
            SWmodel.Extension.SelectByID2("Спереди", "PLANE", 0, 0, 0, false, 0, null, 0);

            //хз зачем но видлимо надо (работа со скетчем?)
            SWmodel.SketchManager.InsertSketch(true);


            //сброс выбора элемента/плоскости?????
            SWmodel.ClearSelection2(true);


            //чертеж полигона (шестиугольник)  (что центр, что радиус, что угол)
            SWmodel.SketchManager.CreatePolygon(0, 0, 0, 0, -0.06, 0, 6, true);



            //видимо выбор вида. нужен ли он вообще??????
            SWmodel.ShowNamedView2("*Триметрия", 8);
            SWmodel.ClearSelection2(true);


            //выбор плоскости/эскиза
            SWmodel.Extension.SelectByID2("Эскиз1", "SKETCH", 0, 0, 0, false, 4, null, 0);



            //выдавливание после выбора эскиза (найти что отвечает за расстояние РАССТОЯНИЕ и НАПРАВЛЕНИЕ)
            SWmodel.FeatureManager.FeatureExtrusion2(true, false, false, 0, 0, 0.07, 0.01, false, false, false,
                                                     false, 1.74532925199433E-02, 1.74532925199433E-02, false, false, false, false, true, true, (true), 0, 0,
                                                     false);

            //выбор контура? зачем он?
            SWmodel.SelectionManager.EnableContourSelection = false;

            //       boolstatus = SWmodel.Extension.SelectByID2("Спереди", "PLANE", 0, 0, 0, false, 0, null, 0);
            //      boolstatus = SWmodel.Extension.SelectByID2("Спереди", "PLANE", 0, 0, 0, false, 0, null, 0);
            //     boolstatus = SWmodel.Extension.SelectByID2("Неизвестный", "BROWSERITEM", 0, 0, 0, false, 0, null, 0);


            //снова
            SWmodel.Extension.SelectByID2("Спереди", "PLANE", 0, 0, 0, false, 0, null, 0);
            //и снова
            SWmodel.SketchManager.InsertSketch(true);
            //а зачем очистка после????
            SWmodel.ClearSelection2(true);



            //скетч круг (что центр, что радиус, что угол)
            SWmodel.SketchManager.CreateCircle(0, 0, 0, -0.001067, -0.01027, 0);



            //   SWmodel.SketchManager.CreateCircle(0, 0, 0, CapRadius / 1000, 0, 0);
            //        SWmodel.ClearSelection2(true);
            //    SWmodel.Extension.SelectByID2("Arc1", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);
            //    SWmodel.ClearSelection2(true);



            //выбор кусочка на чертеже, ибо скетч сегмент, почему арк1 и повторяется
            SWmodel.Extension.SelectByID2("Arc1", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);


            //самое простое выдавливание (найти что отвечает за расстояние РАССТОЯНИЕ и НАПРАВЛЕНИЕ)
            SWmodel.FeatureManager.FeatureCut3(true, false, true, 0, 0, 0.07, 0.07, false, false,
                                               false, false, 1.74532925199433E-02, 1.74532925199433E-02, false, false, false, false, false,
                                               true, true, true, true, false, 0, 0, false);

            //очередной сброс (видимо скетча)
            SWmodel.ClearSelection2(true);


            //круг (что центр, что радиус, что угол)
            SWmodel.SketchManager.CreateCircle(0, 0, 0, -0.025609, -0.045216, 0);

            SWmodel.ClearSelection2(true);
            SWmodel.Extension.SelectByID2("Arc1", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);


            SWmodel.FeatureManager.FeatureExtrusion2(true, false, true, 0, 0, 0.02, 0.07, false,
                                                     false, false, false, 1.74532925199433E-02, 1.74532925199433E-02, false, false, false, false,
                                                     true, true, true, 0, 0, false);



            //   SWmodel.Extension.SelectByID2("Спереди", "PLANE", 0, 0, 0, false, 0, null, 0);


            SWmodel.Extension.SelectByID2("Спереди", "PLANE", 0, 0, 0, false, 0, null, 0);
            SWmodel.ClearSelection2(true);


            SWmodel.SketchManager.CreateCircle(0, 0, 0, 0.0008, -0.046816, 0);
            SWmodel.SketchManager.CreateCircle(0, 0, 0, 0, -0.042815, 0);

            //    SWmodel.ClearSelection2(true);
            SWmodel.ClearSelection2(true);


            //почему здесь арк 2, а не арк1 или эскиз1 (какая дуга)
            SWmodel.Extension.SelectByID2("Arc2", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);


            //функция выдавливание
            SWmodel.FeatureManager.FeatureExtrusion2(true, false, true, 0, 0, 0.04, 0.02, false, false, false,
                                                     false, 1.74532925199433E-02, 1.74532925199433E-02, false, false, false, false, true, true, true,
                                                     0, 0, false);
            SWmodel.ClearSelection2(true);


            //скетч функция круг
            SWmodel.SketchManager.CreateCircle(0, 0, 0, 0.001067, -0.009203, 0);



            // выдавливание очередное
            SWmodel.ClearSelection2(true);
            boolstatus = SWmodel.Extension.SelectByID2("Arc1", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);
            SWmodel.FeatureManager.FeatureExtrusion2(true, false, true, 0, 0, 0.05, 0.04, false, false, false,
                                                     false, 1.74532925199433E-02, 1.74532925199433E-02, false, false, false, false, true, true, true, 0, 0, false);



            //   SWmodel.Extension.SelectByID2("", "EDGE", 0, 0, -0.07, false, 0, null, 0);
            //    SWmodel.ClearSelection2(true);
            //      SWmodel.Extension.SelectByID2("", "EDGE", 0, 0, -0.07, false, 0, null, 0);


            //   boolstatus = SWmodel.Extension.SelectByID2("", "EDGE", 0.0053957910507165252, 0.0068470210082978156, -0.06989040670725899, false, 1, null, 0);
            //       SWmodel.Extension.SelectByID2("", "FACE", 0, 0, -0.07, false, 1, null, 0);

            // функция выбора плоскости
            //   SWmodel.Extension.SelectByID2("", "FACE", 0, 0, -0.1, false, 1, null, 0);


            SWmodel.Extension.SelectByID2("Спереди", "PLANE", 0, 0, 0, false, 0, null, 0);
            SWmodel.ClearSelection2(true);

            //сслылка на переменные-массивы???????
            //  SWmodel.Extension.SelectByID2("", "EDGE", 0, 0, -0.07, false, 0, null, 0);

            boolstatus = SWmodel.Extension.SelectByID2("", "FACE", 0, 0, -0.05, false, 1, null, 0);
            Array radiiArray0 = null;

            double[] radiis0     = new double[0];
            Array    dist2Array0 = null;

            double[] dists20         = new double[0];
            Array    conicRhosArray0 = null;

            double[] coniRhos0     = new double[0];
            Array    setBackArray0 = null;

            double[] setBacks0   = new double[0];
            Array    pointArray0 = null;

            double[] points0          = new double[0];
            Array    pointDist2Array0 = null;

            double[] pointsDist20   = new double[0];
            Array    pointRhoArray0 = null;

            double[] pointsRhos0 = new double[0];
            radiiArray0      = radiis0;
            dist2Array0      = dists20;
            conicRhosArray0  = coniRhos0;
            setBackArray0    = setBacks0;
            pointArray0      = points0;
            pointDist2Array0 = pointsDist20;
            pointRhoArray0   = pointsRhos0;
            SWmodel.FeatureManager.FeatureFillet3(195, 0.0050000000000000001, 0.01, 0, 0, 0, 0, radiiArray0, dist2Array0, conicRhosArray0, setBackArray0, pointArray0, pointDist2Array0, pointRhoArray0);
            boolstatus = SWmodel.Extension.SelectByID2("Спереди", "PLANE", 0, 0, 0, false, 0, null, 0);


            /*
             *      boolstatus = SWmodel.Extension.SelectByID2("Сверху", "PLANE", 0, 0, 0, false, 0, null, 0);
             *      SWmodel.ClearSelection2(true);
             *      Array vSkLines = null;
             *      vSkLines = ((Array)(SWmodel.SketchManager.CreatePolygon(0, 0, 0, 0, -0.050000000000000003, 0, 6, true)));
             *      SWmodel.ShowNamedView2("*Триметрия", 8);
             *      SWmodel.ClearSelection2(true);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line1", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line2", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line3", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line4", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line5", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line6", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      Feature myFeature = null;
             *      myFeature = ((Feature)(SWmodel.FeatureManager.FeatureExtrusion2(true, false, true, 0, 0, 0.070000000000000007, 0.01, false, false, false, false, 0.017453292519943334, 0.017453292519943334, false, false, false, false, true, true, true, 0, 0, false)));
             *      SWmodel.ISelectionManager.EnableContourSelection = false;
             *      boolstatus = SWmodel.Extension.SelectByID2("Сверху", "PLANE", 0, 0, 0, false, 0, null, 0);
             *      SWmodel.SketchManager.InsertSketch(true);
             *      SWmodel.ClearSelection2(true);
             *      SketchSegment skSegment = null;
             *      skSegment = ((SketchSegment)(SWmodel.SketchManager.CreateCircle(0.000000, 0.000000, 0.000000, 0.001196, -0.042023, 0.000000)));
             *      SWmodel.ClearSelection2(true);
             *      boolstatus = SWmodel.Extension.SelectByID2("Arc1", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);
             *      myFeature = ((Feature)(SWmodel.FeatureManager.FeatureExtrusion2(true, false, false, 0, 0, 0.01, 0.070000000000000007, false, false, false, false, 0.017453292519943334, 0.017453292519943334, false, false, false, false, true, true, true, 0, 0, false)));
             *      SWmodel.ISelectionManager.EnableContourSelection = false;
             *      boolstatus = SWmodel.Extension.SelectByID2("Сверху", "PLANE", 0, 0, 0, false, 0, null, 0);
             *      SWmodel.ClearSelection2(true);
             *      skSegment = ((SketchSegment)(SWmodel.SketchManager.CreateCircle(0.000000, 0.000000, 0.000000, 0.001196, -0.039331, 0.000000)));
             *      SWmodel.ClearSelection2(true);
             *      skSegment = ((SketchSegment)(SWmodel.SketchManager.CreateCircle(0.000000, 0.000000, 0.000000, 0.001495, -0.035144, 0.000000)));
             *      SWmodel.ClearSelection2(true);
             *      boolstatus = SWmodel.Extension.SelectByID2("Arc2", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);
             *      myFeature = ((Feature)(SWmodel.FeatureManager.FeatureExtrusion2(true, false, false, 0, 0, 0.02, 0.01, false, false, false, false, 0.017453292519943334, 0.017453292519943334, false, false, false, false, true, true, true, 0, 0, false)));
             *      SWmodel.ISelectionManager.EnableContourSelection = false;
             *      boolstatus = SWmodel.Extension.SelectByID2("Сверху", "PLANE", 0, 0, 0, false, 0, null, 0);
             *      SWmodel.ClearSelection2(true);
             *      skSegment = ((SketchSegment)(SWmodel.SketchManager.CreateCircle(0.000000, 0.000000, 0.000000, -0.000299, -0.008823, 0.000000)));
             *      boolstatus = SWmodel.Extension.SelectByID2("Сверху", "PLANE", 0, 0, 0, false, 0, null, 0);
             *      SWmodel.ClearSelection2(true);
             *      vSkLines = ((Array)(SWmodel.SketchManager.CreatePolygon(0, 0, 0, 0, -0.050000000000000003, 0, 6, true)));
             *      SWmodel.ShowNamedView2("*Триметрия", 8);
             *      SWmodel.ClearSelection2(true);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line1", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line2", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line3", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line4", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line5", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line6", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      myFeature = ((Feature)(SWmodel.FeatureManager.FeatureExtrusion2(true, false, true, 0, 0, 0.070000000000000007, 0.01, false, false, false, false, 0.017453292519943334, 0.017453292519943334, false, false, false, false, true, true, true, 0, 0, false)));
             *      SWmodel.ISelectionManager.EnableContourSelection = false;
             *      boolstatus = SWmodel.Extension.SelectByID2("Сверху", "PLANE", 0, 0, 0, false, 0, null, 0);
             *      SWmodel.ClearSelection2(true);
             *      skSegment = ((SketchSegment)(SWmodel.SketchManager.CreateCircle(0.000000, 0.000000, 0.000000, -0.001196, -0.041724, 0.000000)));
             *      SWmodel.ClearSelection2(true);
             *      boolstatus = SWmodel.Extension.SelectByID2("Arc1", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Сверху", "PLANE", 0, 0, 0, false, 0, null, 0);
             *      SWmodel.ClearSelection2(true);
             *      vSkLines = ((Array)(SWmodel.SketchManager.CreatePolygon(0, 0, 0, 0, -0.050000000000000003, 0, 6, true)));
             *      SWmodel.ShowNamedView2("*Триметрия", 8);
             *      SWmodel.ClearSelection2(true);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line1", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line2", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line3", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line4", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line5", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("Line6", "SKETCHSEGMENT", 0, 0, 0, true, 0, null, 0);
             *      myFeature = ((Feature)(SWmodel.FeatureManager.FeatureExtrusion2(true, false, true, 0, 0, 0.070000000000000007, 0.01, false, false, false, false, 0.017453292519943334, 0.017453292519943334, false, false, false, false, true, true, true, 0, 0, false)));
             *      SWmodel.ISelectionManager.EnableContourSelection = false;
             *      boolstatus = SWmodel.Extension.SelectByID2("Сверху", "PLANE", 0, 0, 0, false, 0, null, 0);
             *      SWmodel.ClearSelection2(true);
             *      skSegment = ((SketchSegment)(SWmodel.SketchManager.CreateCircle(0.000000, 0.000000, 0.000000, -0.000598, -0.010020, 0.000000)));
             *
             *      SWmodel.ClearSelection2(true);
             *      boolstatus = SWmodel.Extension.SelectByID2("Arc1", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);
             *      myFeature = ((Feature)(SWmodel.FeatureManager.FeatureCut3(true, false, false, 0, 0, 0.070000000000000007, 0.070000000000000007, false, false, false, false, 0.017453292519943334, 0.017453292519943334, false, false, false, false, false, true, true, true, true, false, 0, 0, false)));
             *      SWmodel.ISelectionManager.EnableContourSelection = false;
             *      boolstatus = SWmodel.Extension.SelectByID2("Сверху", "PLANE", 0, 0, 0, false, 0, null, 0);
             *      SWmodel.ClearSelection2(true);
             *      skSegment = ((SketchSegment)(SWmodel.SketchManager.CreateCircle(0.000000, 0.000000, 0.000000, 0.001196, -0.039630, 0.000000)));
             *      SWmodel.ClearSelection2(true);
             *      boolstatus = SWmodel.Extension.SelectByID2("Arc1", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);
             *      myFeature = ((Feature)(SWmodel.FeatureManager.FeatureExtrusion2(true, false, false, 0, 0, 0.01, 0.070000000000000007, false, false, false, false, 0.017453292519943334, 0.017453292519943334, false, false, false, false, true, true, true, 0, 0, false)));
             *      SWmodel.ISelectionManager.EnableContourSelection = false;
             *      boolstatus = SWmodel.Extension.SelectByID2("Сверху", "PLANE", 0, 0, 0, false, 0, null, 0);
             *      SWmodel.ClearSelection2(true);
             *      skSegment = ((SketchSegment)(SWmodel.SketchManager.CreateCircle(0.000000, 0.000000, 0.000000, 0.000897, -0.035742, 0.000000)));
             *      SWmodel.ClearSelection2(true);
             *      skSegment = ((SketchSegment)(SWmodel.SketchManager.CreateCircle(0.000000, 0.000000, 0.000000, 0.001196, -0.029461, 0.000000)));
             *      SWmodel.ClearSelection2(true);
             *      boolstatus = SWmodel.Extension.SelectByID2("Arc2", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);
             *      myFeature = ((Feature)(SWmodel.FeatureManager.FeatureExtrusion2(true, false, false, 0, 0, 0.029999999999999999, 0.01, false, false, false, false, 0.017453292519943334, 0.017453292519943334, false, false, false, false, true, true, true, 0, 0, false)));
             *      SWmodel.ISelectionManager.EnableContourSelection = false;
             *      boolstatus = SWmodel.Extension.SelectByID2("Сверху", "PLANE", 0, 0, 0, false, 0, null, 0);
             *      SWmodel.ClearSelection2(true);
             *      skSegment = ((SketchSegment)(SWmodel.SketchManager.CreateCircle(0.000000, 0.000000, 0.000000, 0.000299, -0.009421, 0.000000)));
             *      SWmodel.ClearSelection2(true);
             *      boolstatus = SWmodel.Extension.SelectByID2("Arc1", "SKETCHSEGMENT", 0, 0, 0, false, 0, null, 0);
             *      myFeature = ((Feature)(SWmodel.FeatureManager.FeatureExtrusion2(true, false, false, 0, 0, 0.050000000000000003, 0.029999999999999999, false, false, false, false, 0.017453292519943334, 0.017453292519943334, false, false, false, false, true, true, true, 0, 0, false)));
             *      SWmodel.ISelectionManager.EnableContourSelection = false;
             *
             *
             *
             *   //   boolstatus = SWmodel.Extension.SelectByID2("", "EDGE", -0.0092719068117216308, 0.050000000000011369, -0.00014954688406061358, false, 0, null, 0);
             *      boolstatus = SWmodel.Extension.SelectByID2("", "FACE", -0.0020936563768404193, 0.050000000000011369, 0.0037386721015000464, false, 0, null, 0);
             *      SWmodel.ClearSelection2(true);
             *      boolstatus = SWmodel.Extension.SelectByID2("", "FACE", -0.0020936563768404193, 0.050000000000011369, 0.0037386721015000464, false, 1, null, 0);
             *      Array radiiArray0 = null;
             *      double[] radiis0 = new double[0];
             *      Array dist2Array0 = null;
             *      double[] dists20 = new double[0];
             *      Array conicRhosArray0 = null;
             *      double[] coniRhos0 = new double[0];
             *      Array setBackArray0 = null;
             *      double[] setBacks0 = new double[0];
             *      Array pointArray0 = null;
             *      double[] points0 = new double[0];
             *      Array pointDist2Array0 = null;
             *      double[] pointsDist20 = new double[0];
             *      Array pointRhoArray0 = null;
             *      double[] pointsRhos0 = new double[0];
             *      radiiArray0 = radiis0;
             *      dist2Array0 = dists20;
             *      conicRhosArray0 = coniRhos0;
             *      setBackArray0 = setBacks0;
             *      pointArray0 = points0;
             *      pointDist2Array0 = pointsDist20;
             *      pointRhoArray0 = pointsRhos0;
             *      myFeature = ((Feature)(SWmodel.FeatureManager.FeatureFillet3(195, 0.0050000000000000001, 0.01, 0, 0, 0, 0, radiiArray0, dist2Array0, conicRhosArray0, setBackArray0, pointArray0, pointDist2Array0, pointRhoArray0)));
             *      boolstatus = SWmodel.Extension.SelectByID2("Сверху", "PLANE", 0, 0, 0, false, 0, null, 0);
             *      myModelView = ((ModelView)(SWmodel.ActiveView));
             *      myModelView.RotateAboutCenter(0, -0.015745452440426206);
             *      myModelView = ((ModelView)(SWmodel.ActiveView));
             *      myModelView.RotateAboutCenter(-0.0061313611268945913, 0);
             *      myModelView = ((ModelView)(SWmodel.ActiveView));
             *      myModelView.RotateAboutCenter(0, -0.015745452440426206);
             *      myModelView = ((ModelView)(SWmodel.ActiveView));
             *      myModelView.RotateAboutCenter(0, -0.015745452440426206);
             *      myModelView = ((ModelView)(SWmodel.ActiveView));
             *      myModelView.RotateAboutCenter(-0.0061313611268945913, 0);
             *
             */
        }