Esempio n. 1
0
 public void AKR_CreatePlanBlocks()
 {
     CommandStart.Start(doc =>
     {
         var mountingPlans = new MountingsPlans.BlockPlans();
         mountingPlans.CreateBlockPlans();
     });
 }
Esempio n. 2
0
        private List <ObjectId> CreateMountingPlanBlocks(List <Workspace> wsList)
        {
            var idsBlRefMount = new List <ObjectId>();

            foreach (var ws in wsList)
            {
                var floorBlockName = BlockPlans.GetFloorBlockName(ws.Floor, ws.Section);
                try
                {
                    var idBlRefMount = BlockPlans.CreateBlock(ws.IdsElementInWS, floorBlockName, ws.AxisPosition);
                    idsBlRefMount.Add(idBlRefMount);
                }
                catch (Exception ex)
                {
                    Inspector.AddError($"Ошибка создания блока монтажного плана '{ws}' : {ex.Message}", ws.Extents, Matrix3d.Identity, System.Drawing.SystemIcons.Error);
                }
            }
            return(idsBlRefMount);
        }