/// <summary>The AddIn loader creates an instance of a class /// derived from Bentley.MicroStation.AddIn and invokes Run. /// </summary> protected override int Run(System.String[] commandLine) { s_comApp = BMI.Utilities.ComApp; // Register reload and unload events, and show the form this.ReloadEvent += new ReloadEventHandler(AddInMain_ReloadEvent); this.UnloadedEvent += new UnloadedEventHandler(AddInMain_UnloadedEvent); BoltControl.ShowForm(this); return(0); }
protected override void OnUnloading(UnloadingEventArgs eventArgs) { BoltControl.CloseForm(); base.OnUnloading(eventArgs); }
/// <summary>Handles MDL LOAD requests after the application has been loaded. /// </summary> private void AddInMain_ReloadEvent(Bentley.MicroStation.AddIn sender, ReloadEventArgs eventArgs) { BoltControl.ShowForm(this); }