Beispiel #1
0
        public IntelliSenseTextBox()
            : base()
        {
            Visible = true;

            ShortcutsEnabled = false;
            combobox         = new UserControlLibrary.ComboAutoDropDownWidth();
            combobox.Parent  = this;
            combobox.SelectionChangeCommitted += combobox_SelectionChangeCommitted;
            combobox.RightClickDropDown       += combobox_RightClickDropDown;
            combobox.Visible = false;
            Controls.Add(combobox);
            combobox.BringToFront();
            dictionary = new List <string>();
        }
Beispiel #2
0
 public TextBoxAutoComplete()
 {
     InitializeComponent();
     txtBox                  = new TextBox();
     txtBox.Dock             = DockStyle.Fill;
     txtBox.BorderStyle      = System.Windows.Forms.BorderStyle.FixedSingle;
     txtBox.AutoCompleteMode = AutoCompleteMode.Append;
     txtBox.TextChanged     += new EventHandler(txtBox_TextChanged);
     txtBox.KeyDown         += new KeyEventHandler(txtBox_KeyDown);
     txtBox.Leave           += new EventHandler(txtBox_LostFocus);
     txtBox.Resize          += new EventHandler(txtBox_Resize);
     txtBox.MouseWheel      += new MouseEventHandler(txtBox_MouseWheel);
     this.Controls.Add(txtBox);
     cmbBox                           = new UserControlLibrary.ComboAutoDropDownWidth();
     cmbBox.TabStop                   = false;
     cmbBox.DropDownHeight            = 200;
     cmbBox.SelectionChangeCommitted += new EventHandler(cmbBox_SelectionChangeCommitted);
     this.Controls.Add(cmbBox);
 }