![]() |
combobox
I am using Excel 97, I have an array in vba for the
dropdown. If a user types something in the combobox which isn't in the array, is there a way to check the array and if it isn't listed to continue and change the entry of another cell say? Can someone help please? Mark |
combobox
I think from your post you need to look at the limit to
list of the combo. -----Original Message----- I am using Excel 97, I have an array in vba for the dropdown. If a user types something in the combobox which isn't in the array, is there a way to check the array and if it isn't listed to continue and change the entry of another cell say? Can someone help please? Mark . |
combobox
Can you explain further, please?
Mark -----Original Message----- I think from your post you need to look at the limit to list of the combo. -----Original Message----- I am using Excel 97, I have an array in vba for the dropdown. If a user types something in the combobox which isn't in the array, is there a way to check the array and if it isn't listed to continue and change the entry of another cell say? Can someone help please? Mark . . |
combobox
Hello Mark
Not too sure I understand! If you wish to have an additionnal element in your combo and your source range when user types a non-matching value then you could do something like this (please amend accordingly and note that I am referencing the sheet's codename and items are added with the combobox.Additem method in the Userform_Initialize event): Private Sub ComboBox1_AfterUpdate() If Not ComboBox1.MatchFound Then If MsgBox("Add new item " & ComboBox1.Value, vbYesNo + vbQuestion, _ "Not in list") = vbYes Then ComboBox1.AddItem ComboBox1.Value Feuil1.Range("A65536").End(xlUp)(2).Value = ComboBox1.Value End If End If End Sub HTH Cordially Pascal "Mark" a écrit dans le message de ... I am using Excel 97, I have an array in vba for the dropdown. If a user types something in the combobox which isn't in the array, is there a way to check the array and if it isn't listed to continue and change the entry of another cell say? Can someone help please? Mark |
All times are GMT +1. The time now is 11:49 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com