Java – Basics in Flex and ActionScript

apache-flexjava

I have a class with a method name, and now i have a Flex MXML… how would i call the id of the component in my ActionScript class…

Best Answer

You don't actually "call the id" of a component, though you can reference it simply by using the id in your ActionScript code, e.g.

myMap.toMapFromStage(event.stageX, event.stageY);

where myMap is an ArcGIS map object (taken from here: http://resources.esri.com/help/9.3/arcgisserver/apis/flex/samples/index.html; click the Source Code tab to see the example).

I strongly recommend looking at all of the information Adobe has put together to learn about Flex. They have an excellent site with tutorials, coding samples, etc., that should get you up to speed pretty quickly. It's at http://www.adobe.com/devnet/flex/.