I got the question again from Girish
He was trying to resize the map whenever you try to change the size of the vdividedbox component.
Here is the link –>
http://digitallyinsane.wordpress.com/2007/04/05/show-the-marker-on-the-map-on-the-click-on-the-map/
I tried to digg in to the problem and found out that if u want to change the size of the map on resizing the container you need to provide the min width and min height in the source provided by yahoo
Check out this article in Flex docs
http://livedocs.adobe.com/flex/2/docs/wwhelp/wwhimpl/js/html/wwhelp.htm?href=00001733.html
Its saying about setting the minimum height and width of the component and my guess is that u have to set that in the YahooMapService.as file.
I am trying to look into that but busy with some other work.
Here is one more alternative that can be done
Instead of putting a container inside the vdividedbox and putting a map inside it, put map directly inside the vdividedbox and set the width and height of the yahoo map component as 80% and you will be able to resize it.
Here is the code
<mx:VDividedBox id=”vdb” right=”5″ top=”5″ bottom=”5″ left=”285″ >
<yahoo:YahooMapService
id=”myAS2Map”
UUID=”12345″
swfDomId=”{SWFDOMID}”
apiId=”{YAHOOAPIKEY}”
mapURL = “{MAPSWF}” height=”80%” width=”80%”
x=”10″ y=”10″/>
<mx:Canvas height=”100%” width=”100%” >
<mx:Label
text=”Add Components here”
fontWeight=”bold”/>
</mx:Canvas>
</mx:VDividedBox>
I hope this helps.
If there is anything else do write it to me.
Cheers!
Anupam




