Here are the examples of the csharp api class System.Windows.Forms.AutoCompleteStringCollection.AddRange(string[]) taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.
31 Examples
0
1. Example
View licenseprivate void ReviewersDataGridEditingControlShowing(object sender, DataGridViewEditingControlShowingEventArgs e) { var cellEdit = e.Control as DataGridViewTextBoxEditingControl; if (cellEdit != null) { cellEdit.AutoCompleteCustomSource = new AutoCompleteStringCollection(); cellEdit.AutoCompleteMode = AutoCompleteMode.SuggestAppend; cellEdit.AutoCompleteSource = AutoCompleteSource.CustomSource; cellEdit.AutoCompleteCustomSource.AddRange(_stashUsers.ToArray()); } }
0
2. Example
View licensevoid LoadKnownAddresses() { _knownAddresses = new AutoCompleteStringCollection(); _formReadAddress.SetKnownAddressList(_knownAddresses); string[] lines; try { lines = File.ReadAllLines(_knownAddressesPath); } catch (FileNotFoundException) { return; } _knownAddresses.AddRange(lines); }
0
3. Example
View licensepublic override object Clone() { KryptonDataGridViewComboBoxColumn cloned = base.Clone() as KryptonDataGridViewComboBoxColumn; // Convert collection of strings to an array string[] strings = new string[Items.Count]; for (int i = 0; i < strings.Length; i++) strings[i] = Items[i]; cloned.Items.AddRange(strings); // Convert collection of strings to an array strings = new string[AutoCompleteCustomSource.Count]; for (int i = 0; i < strings.Length; i++) strings[i] = AutoCompleteCustomSource[i]; cloned.AutoCompleteCustomSource.AddRange(strings); // Move the button specs over to the new clone foreach (ButtonSpec bs in ButtonSpecs) cloned.ButtonSpecs.Add(bs.Clone()); return cloned; }
0
4. Example
View licenseprivate void main_Load(object sender, EventArgs e) { configItemBindingSource.DataSource = items; var source = new AutoCompleteStringCollection(); source.AddRange(Games.Select(x => x.Name).ToArray()); inputAppID.AutoCompleteCustomSource = source; inputAppID.AutoCompleteSource = AutoCompleteSource.CustomSource; inputAppID.AutoCompleteMode = AutoCompleteMode.SuggestAppend; }
0
5. Example
View licenseprotected void PopulateXenServerHosts() { AutoCompleteStringCollection history = Settings.GetServerHistory(); string[] historyArray = new string[history.Count]; history.CopyTo(historyArray, 0); Array.Sort(historyArray, StringUtility.NaturalCompare); foreach (string serverName in historyArray) { if (serverName != null) ServerNameComboBox.Items.Add(serverName); } // Use a clone as the auto-complete source because of CA-38715 AutoCompleteStringCollection historyClone = new AutoCompleteStringCollection(); historyClone.AddRange(historyArray); ServerNameComboBox.AutoCompleteCustomSource = historyClone; }
0
6. Example
View licenseprivate void updateTribeSuggestions() { var l = new AutoCompleteStringCollection(); l.AddRange(tribes.Select(t => t.TribeName).ToArray()); textBoxPlayerTribe.AutoCompleteCustomSource = l; }
0
7. Example
View licenseprivate void TagComplexEditor_Load(object sender, System.EventArgs e) { if (_tag == null) return; if (string.IsNullOrEmpty(_tag.TagReadText)) { _dict = new Dictionary<string, string>(); } else { _dict = _tag.TagReadText.GetListFromText(); foreach (var item in _dict) { dataGridView1.Rows.Add(item.Key, item.Value); } } var list = TagList.GetTagNameList(); scAutoComplete.AddRange(list.ToArray()); _top = new TreeNode(_tag.Node); treeView1.Nodes.Add(_top); AddTreeNode(_tag, _top); treeView1.ExpandAll(); //coolTextBox1. = list; this.Validate(); dataGridView1.RowValidating += new DataGridViewCellCancelEventHandler(dataGridView1_RowValidating); }
0
8. Example
View licensevoid SetAutoCompleteSource(TextBox textbox, string setting) { var settings = Properties.Settings.Default; var patternCollection = ((StringCollection)settings[setting]).Cast<string>().ToArray(); var autoCompleteCollection = new AutoCompleteStringCollection(); autoCompleteCollection.AddRange(patternCollection); textbox.AutoCompleteCustomSource = autoCompleteCollection; textbox.Text = patternCollection.FirstOrDefault(); }
0
9. Example
View licensevoid SetAutoCompleteSource(TextBox textbox, string setting) { var settings = Properties.Settings.Default; var patternCollection = ((StringCollection)settings[setting]).Cast<string>().ToArray(); var autoCompleteCollection = new AutoCompleteStringCollection(); autoCompleteCollection.AddRange(patternCollection); textbox.AutoCompleteCustomSource = autoCompleteCollection; textbox.Text = patternCollection.FirstOrDefault(); }
0
10. Example
View licenseprivate void InitializeComponent() { this.components = new System.ComponentModel/n ..... /n //View Source file for more details /n }
0
11. Example
View licenseprivate void InitializeComponent() { this.components = new System.ComponentModel/n ..... /n //View Source file for more details /n }
0
12. Example
View licensepublic void RebuildAutoCompleteSource() { AutocompleteSource.AddRange(FileList.Select(x => GetFileName(x.Name)).Distinct().ToArray()); }
0
13. Example
View licensepublic void RebuildAutoCompleteSource() { AutocompleteSource.AddRange(FileList.Select(x => GetFileName(x.Name)).Distinct().ToArray()); }
0
14. Example
View licensepublic void RebuildAutoCompleteSource() { AutocompleteSource.AddRange(FileList.Select(x => GetFileName(x.Name)).Distinct().ToArray()); }
0
15. Example
View licenseprivate void InitializeComponent() { this.lblInstructions = new System.Windows.F/n ..... /n //View Source file for more details /n }
0
16. Example
View licensepublic void InitToolStripBranchFilter() { bool local = localToolStripMenuItem.Checked; bool tag = tagsToolStripMenuItem.Checked; bool remote = remoteToolStripMenuItem.Checked; _NO_TRANSLATE_toolStripBranches.Items.Clear(); if (Module.IsValidGitWorkingDir()) { AsyncLoader.DoAsync(() => GetBranchAndTagRefs(local, tag, remote), branches => { foreach (var branch in branches) _NO_TRANSLATE_toolStripBranches.Items.Add(branch); var autoCompleteList = _NO_TRANSLATE_toolStripBranches.AutoCompleteCustomSource.Cast<string>(); if (!autoCompleteList.SequenceEqual(branches)) { _NO_TRANSLATE_toolStripBranches.AutoCompleteCustomSource.Clear(); _NO_TRANSLATE_toolStripBranches.AutoCompleteCustomSource.AddRange(branches.ToArray()); } }); } _NO_TRANSLATE_toolStripBranches.Enabled = Module.IsValidGitWorkingDir(); }
0
17. Example
View licensepublic void ConfigureAutoComplete(TextBox tb, OLVColumn column, int maxRows) { // Don't consider more rows than we actually have maxRows = Math.Min(this.GetItemCount(), maxRows); // Reset any existing autocomplete tb.AutoCompleteCustomSource.Clear(); // CONSIDER: Should we use ClusteringStrategy here? // Build a list of unique values, to be used as autocomplete on the editor Dictionary<string, bool> alreadySeen = new Dictionary<string, bool>(); List<string> values = new List<string>(); for (int i = 0; i < maxRows; i++) { string valueAsString = column.GetStringValue(this.GetModelObject(i)); if (!String.IsNullOrEmpty(valueAsString) && !alreadySeen.ContainsKey(valueAsString)) { values.Add(valueAsString); alreadySeen[valueAsString] = true; } } tb.AutoCompleteCustomSource.AddRange(values.ToArray()); tb.AutoCompleteSource = AutoCompleteSource.CustomSource; tb.AutoCompleteMode = column.AutoCompleteEditorMode; }
0
18. Example
View licenseprivate void InitializeComponent() { System.ComponentModel.ComponentResourceManager resources = n/n ..... /n //View Source file for more details /n }
0
19. Example
View licensepublic void ConfigureAutoComplete(TextBox tb, OLVColumn column, int maxRows) { // Don't consider more rows than we actually have maxRows = Math.Min(GetItemCount(), maxRows); // Reset any existing autocomplete tb.AutoCompleteCustomSource.Clear(); // CONSIDER: Should we use ClusteringStrategy here? // Build a list of unique values, to be used as autocomplete on the editor var alreadySeen = new Dictionary<string, bool>(); var values = new List<string>(); for (int i = 0; i < maxRows; i++) { string valueAsString = column.GetStringValue(GetModelObject(i)); if (!String.IsNullOrEmpty(valueAsString) && !alreadySeen.ContainsKey(valueAsString)) { values.Add(valueAsString); alreadySeen[valueAsString] = true; } } tb.AutoCompleteCustomSource.AddRange(values.ToArray()); tb.AutoCompleteSource = AutoCompleteSource.CustomSource; tb.AutoCompleteMode = column.AutoCompleteEditorMode; }
0
20. Example
View licensepublic void ConfigureAutoComplete(TextBox tb, OLVColumn column, int maxRows) { // Don't consider more rows than we actually have maxRows = Math.Min(GetItemCount(), maxRows); // Reset any existing autocomplete tb.AutoCompleteCustomSource.Clear(); // CONSIDER: Should we use ClusteringStrategy here? // Build a list of unique values, to be used as autocomplete on the editor var alreadySeen = new Dictionary<string, bool>(); var values = new List<string>(); for (int i = 0; i < maxRows; i++) { string valueAsString = column.GetStringValue(GetModelObject(i)); if (!String.IsNullOrEmpty(valueAsString) && !alreadySeen.ContainsKey(valueAsString)) { values.Add(valueAsString); alreadySeen[valueAsString] = true; } } tb.AutoCompleteCustomSource.AddRange(values.ToArray()); tb.AutoCompleteSource = AutoCompleteSource.CustomSource; tb.AutoCompleteMode = column.AutoCompleteEditorMode; }
0
21. Example
View licenseprivate void InitializeComponent() { this.components = new System.ComponentModel/n ..... /n //View Source file for more details /n }
0
22. Example
View licenseprivate void InitializeComponent() { this.components = new System.ComponentModel/n ..... /n //View Source file for more details /n }
0
23. Example
View licensepublic void ConfigureAutoComplete(TextBox tb, OLVColumn column, int maxRows) { // Don't consider more rows than we actually have maxRows = Math.Min(this.GetItemCount(), maxRows); // Reset any existing autocomplete tb.AutoCompleteCustomSource.Clear(); // CONSIDER: Should we use ClusteringStrategy here? // Build a list of unique values, to be used as autocomplete on the editor Dictionary<string, bool> alreadySeen = new Dictionary<string, bool>(); List<string> values = new List<string>(); for (int i = 0; i < maxRows; i++) { string valueAsString = column.GetStringValue(this.GetModelObject(i)); if (!String.IsNullOrEmpty(valueAsString) && !alreadySeen.ContainsKey(valueAsString)) { values.Add(valueAsString); alreadySeen[valueAsString] = true; } } tb.AutoCompleteCustomSource.AddRange(values.ToArray()); tb.AutoCompleteSource = AutoCompleteSource.CustomSource; tb.AutoCompleteMode = column.AutoCompleteEditorMode; }
0
24. Example
View licenseprivate void InitializeComponent() { this.components = new System.ComponentM/n ..... /n //View Source file for more details /n }
0
25. Example
View licensepublic void ConfigureAutoComplete(TextBox tb, OLVColumn column, int maxRows) { // Don't consider more rows than we actually have maxRows = Math.Min(this.GetItemCount(), maxRows); // Reset any existing autocomplete tb.AutoCompleteCustomSource.Clear(); // CONSIDER: Should we use ClusteringStrategy here? // Build a list of unique values, to be used as autocomplete on the editor Dictionary<string, bool> alreadySeen = new Dictionary<string, bool>(); List<string> values = new List<string>(); for (int i = 0; i < maxRows; i++) { string valueAsString = column.GetStringValue(this.GetModelObject(i)); if (!String.IsNullOrEmpty(valueAsString) && !alreadySeen.ContainsKey(valueAsString)) { values.Add(valueAsString); alreadySeen[valueAsString] = true; } } tb.AutoCompleteCustomSource.AddRange(values.ToArray()); tb.AutoCompleteSource = AutoCompleteSource.CustomSource; tb.AutoCompleteMode = column.AutoCompleteEditorMode; }
0
26. Example
View licensepublic void ConfigureAutoComplete(TextBox tb, OLVColumn column, int maxRows) { // Don't consider more rows than we actually have maxRows = Math.Min(this.GetItemCount(), maxRows); // Reset any existing autocomplete tb.AutoCompleteCustomSource.Clear(); // CONSIDER: Should we use ClusteringStrategy here? // Build a list of unique values, to be used as autocomplete on the editor Dictionary<string, bool> alreadySeen = new Dictionary<string, bool>(); List<string> values = new List<string>(); for (int i = 0; i < maxRows; i++) { string valueAsString = column.GetStringValue(this.GetModelObject(i)); if (!String.IsNullOrEmpty(valueAsString) && !alreadySeen.ContainsKey(valueAsString)) { values.Add(valueAsString); alreadySeen[valueAsString] = true; } } tb.AutoCompleteCustomSource.AddRange(values.ToArray()); tb.AutoCompleteSource = AutoCompleteSource.CustomSource; tb.AutoCompleteMode = column.AutoCompleteEditorMode; }
0
27. Example
View licenseprivate void InitializeComponent() { System.ComponentModel.ComponentResourceManager resour/n ..... /n //View Source file for more details /n }
0
28. Example
View licenseprivate void InitializeComponent() { this.components = new System.ComponentModel/n ..... /n //View Source file for more details /n }
0
29. Example
View licenseprivate void InitializeComponent() { this.components = new System.ComponentModel/n ..... /n //View Source file for more details /n }
0
30. Example
View license[System.Diagnostics.DebuggerStepThrough()] private void InitializeComponent() /n ..... /n //View Source file for more details /n }
0
31. Example
View licenseprivate void InitializeComponent() { this.components = new System.ComponentModel/n ..... /n //View Source file for more details /n }