Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
New Contributor
Posts: 4
Registered: ‎10-03-2012
My Device: Torch 9850

QML onSelectedChanged

[ Edited ]

Within my drop down box I have several options. When each option is selected, it changes the background color of a certain container as seen below

onSelectedChanged: {
                                secondColorBand.background = Color.Black
                            }

When the user selects the first option, it will change things correctly. When the user selects a second option (within same drop down box) it will do nothing. When a third option is selected, it changes things to what the second option should have done. The fourth will change things to the third, etc. How do I fix this?

 

Any help is greatly appreciated, thanks :smileyhappy:

New Contributor
Posts: 4
Registered: ‎10-03-2012
My Device: Torch 9850

Re: QML onSelectedChanged

Someone said it might be an indexing problem, but I don't know how to fix it or what the index numbers should be for each container, etc.

Developer
Posts: 1,523
Registered: ‎12-18-2012
My Device: Z30, Z10 LE, DevAlpha C, PlayBook

Re: QML onSelectedChanged

Can you please post the complete QML code?


Andrey Fidrya, @zmeyc on twitter