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. New to the forum? Please visit the ‘Getting Started’ link below.
inside custom component

Cascades Development

Reply
Trusted Contributor
gdev001
Posts: 163
Registered: ‎01-30-2013
Accepted Solution

Action items get duplicated - why?

Hi,

 

I have this code for adding action item to my page:

 

...
          
    actions: [
        ActionItem {
            title: "Action 1"
            ActionBar.placement: ActionBarPlacement.OnBar
              
            onTriggered: {
                myLabel.text = "Action 1 selected!"
            }
        }
    ]
    
....

} // end of Page

 In the QML preview, just one action item is shown as above -- but when I run the application, there are two duplicates of the above action item. Does anyone have any idea why? Thanks.

Please use plain text.
Developer
peter9477
Posts: 5,821
Registered: ‎12-08-2010
My Carrier: none

Re: Action items get duplicated - why?

Refer to this post: http://supportforums.blackberry.com/t5/Cascades-Development/Duplicate-actionbar-buttons/m-p/2157969#...

Peter Hansen -- (PlayBook and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Please use plain text.