public Result Execute(ExternalCommandData commandData, ref string message, ElementSet elements) { UIApplication application = commandData.Application; UIDocument activeUIDocument = application.ActiveUIDocument; Application application2 = application.Application; Document document = activeUIDocument.Document; Selection selection = activeUIDocument.Selection; LegendManager data = new LegendManager(document); using (LegendManagerForm legendManagerForm = new LegendManagerForm(data)) { legendManagerForm.ShowDialog(); } return(Result.Succeeded); }
public LegendManagerForm(LegendManager data) { this._data = data; this.InitializeComponent(); this.cbType.SelectedIndex = 0; }