Reputation: 17
I have created an accordion to store images on categories. Everything is ok when I add a new element to an item, the scroller appears. The image address is saved in an txt file. However, when I open the application again the scroller does not appear. This is strange as it happens only in the first item of the accordion. If I add more elements to the other items (from the second further) everything works alright. Does anybody have any idea why??
Upvotes: 0
Views: 219
Reputation: 699
In accordion just write resizetocontent = true; It will work
Hope it will help
Upvotes: 0
Reputation: 328
Hard to say without seeing your code. Sample of using accordion with images inside which you can try (scrollbars are visible for both tabs):
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:mx="library://ns.adobe.com/flex/mx">
<mx:Accordion height="500"
width="100%">
<s:NavigatorContent label="Tab 1"
height="100%"
width="100%">
<s:Scroller height="100%"
width="100%">
<s:Group>
<s:Image source="http://d1c739w2xm33i4.cloudfront.net/2.2/top_image.jpg"/>
</s:Group>
</s:Scroller>
</s:NavigatorContent>
<s:NavigatorContent label="Tab 2"
height="100%"
width="100%">
<s:Scroller height="100%"
width="100%">
<s:Group>
<s:Image source="http://eofdreams.com/data_images/dreams/image/image-07.jpg"/>
</s:Group>
</s:Scroller>
</s:NavigatorContent>
</mx:Accordion>
</s:Application>
Upvotes: 1