I have a ComboBox dropdown menu that is populated by a database of character names.
I have a function that removed the selected character name from the database and re-selects the currently logged in character.
The problem is, I want to remove that name from the drop down list when this function files.
I have tried GetItems() UpdateItems() and others to no avail.
Does anyone know how to update the list?
I used this to populate it:
Code:
for k, v in pairs(nameList) do
local entry = charnameDropdown.dropdown:CreateItemEntry(v, OnItemSelect)
charnameDropdown.dropdown:AddItem(entry)
end
I can't seem to find a RemoveItem() function...
It seems if I can re-initialize the main control I can just rebuild it. I'm not sure how to "delete" a control though.
Can I just set it to nil and re-run my initialization function? Testing...
EDIT: Yeah... no. That didn't work. "Duplicate name" still exists.