/// <summary> /// Displays Rhino's combo list box. /// </summary> /// <param name="title">The dialog title.</param> /// <param name="message">The dialog message.</param> /// <param name="items">A list of items to show.</param> /// <returns> /// <para>selected item.</para> /// <para>null if the user canceled.</para> /// </returns> public static object ShowComboListBox(string title, string message, System.Collections.IList items) { object rc = null; if (items != null && items.Count > 0) { ComboListBoxForm dlg = new ComboListBoxForm(title, message, items); if (dlg.ShowDialog(RhinoApp.MainWindow()) == System.Windows.Forms.DialogResult.OK) { rc = dlg.SelectedItem(); } } return(rc); }
/// <summary> /// Displays Rhino's combo list box. /// </summary> /// <param name="title">The dialog title.</param> /// <param name="message">The dialog message.</param> /// <param name="items">A list of items to show.</param> /// <returns> /// <para>selected item.</para> /// <para>null if the user canceled.</para> /// </returns> public static object ShowComboListBox(string title, string message, System.Collections.IList items) { object rc = null; if (items != null && items.Count > 0) { ComboListBoxForm dlg = new ComboListBoxForm(title, message, items); if (dlg.ShowDialog(RhinoApp.MainWindow()) == System.Windows.Forms.DialogResult.OK) rc = dlg.SelectedItem(); } return rc; }