Thread Tools Display Modes
Prev Previous Post   Next Post Next
04/22/14, 07:07 PM   #1
TheBelgarion
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 13
Updating Dropdown select new value

HI

i tried using LAM:AddDropdown() in my Setting Panel.

I wanted to change the value of a second Dropdown if i select something else in the first and even the dropdown prefix.

So i did a SetFunction on dropdown 1

Code:
BAM.selectItemTypeSetFunc = function(itemType)
    local dropdown = BAM.elements.secondDropdown
    local dropmenu = dropdown:GetNamedChild("Dropdown")
    BAM.dm = dropmenu
    dropdown.text = itemType
    dropmenu.m_comboBox.SetSelectedItem(BAM.defaultBagGetFunc(itemType))
    dropmenu.m_comboBox.SelectItem(BAM.defaultBagGetFunc(itemType))
    ZO_OptionsWindow_InitializeControl(dropmenu)
    ZO_OptionsWindow_InitializeControl(dropdown)
end
the problem is with changing the selected value
dropmenu.m_comboBox.SetSelectedItem does not seem to work ( the value is the correct one checked that already )
even checked with zgoo dropmenu.m_comboBox looks like the right object, but cant change the selected Value somehow.

Not sure which method would be the correct Method to change the Selected Value on a LAM.Dropbox Object.


Any Ideas ?

thx a lot

TheBelgarion
  Reply With Quote
 

ESOUI » Developer Discussions » Lua/XML Help » Updating Dropdown select new value


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off