コード例 #1
0
        public Result Execute(ExternalCommandData commandData, ref string message, ElementSet elements)
        {
            uidoc = commandData.Application.ActiveUIDocument;
            Document doc = uidoc.Document;

            allBeams = new FilteredElementCollector(doc).OfCategory(BuiltInCategory.OST_StructuralFraming).OfClass(typeof(FamilyInstance)).ToList();

            if (allBeams.Count == 0)
            {
                message = Properties.Messages.RenumberBeams_NoBeamFamilyLoaded;
                return(Result.Failed);
            }

            RenumberBeamsUI reBeamsUI = new RenumberBeamsUI();

            if (reBeamsUI.ShowDialog() == true)
            {
                DoTheRenumberingBeams();
            }

            return(Result.Succeeded);
        }
コード例 #2
0
 public RenumberBeamTypesUI(RenumberBeamsUI parentUI)
 {
     InitializeComponent();
     parentBeamUI = parentUI;
 }
コード例 #3
0
 public RenumberBeamLevelUI(RenumberBeamsUI targetParentWindow)
 {
     InitializeComponent();
     parentWindow = targetParentWindow;
 }