actionscript-3

Why can't I access dynamic text within a CS4 compiled SWC?

I have a movieclip created in CS4. I export that into my Flex Project's /lib and then try to access the text. All the textfields have ids, embedded text, and show up in intellisense. But when i run the project, the textfield is blank. What is going on? Edit: It appears to only not work when the text is embedded. Non embedded text works ...

Is actionscript 3.0 strong enough to finally be my sole server-side language?

Actionscript 3.0 is much more powerful than its previous versions. Does this mean that I can start using it as my sole server-side language? can it connect to the database just like coldfusion or php? What is it that it can't do on the server-side? Thanks ...

Show current item as tool tip in ComboBox itemRollOver

Hi, I need to know how to show current item as tool tip in ComboBox itemRollOver event at present i am using the below code, private var tip:ToolTip private function ItemRollOver(event:ListEvent):void { var currComboBox:ComboBox = event.currentTarget as ComboBox; var tipInfo:String = currComboBox.dataProvider[event.rowIndex]....

Is actionscript a client-side or server-side language?

Someone just told me that Actionscript is a client-side language. I'm not sure how this is true if we save the .as files on the server? I also heard several times before people referring to it as a server-side language. Which is true (if you can, please clarify with a reference). Thanks. ...

Flex Datagrid - how to obtain item for mouse x/y coordinates?

Hey folks, my mission is to select an item in a DataGrid instance with nothing but the coordinates on screen. We are implementing right-click functionality in our Flash application, with the goal of being able to right-click a DG row, which would select that row plus show a popup window containing some context commands. I have managed...

Flex Chart : Horizontal line at 0 when having negative values

Hi all, I have a Flex Column Chart, which shows bars with each positive and negative values. I only want to have a horizontal line at 0 to distinguish between positive and negative values. I turned off all the axis. How could I achieve to get this line? Thanks, Martin ...

ExternalInterface-passing dynamic arguments to Javascript function

I'm having a problem passing dynamic variables to a Javascript function using ExternalInterface. The variables don't seem to be resolved correctly //CODE START var customInfo :String='some custom info' ExternalInterface.call("funcName", 'arg1Name', ' "+customInfo+" ') //CODE END In Javascript, I get 'customInfo' literally, it isn't...

Which type of Flash animation performs best for games?

I'm making a multiplayer flash game in Actionscript 3.0, using Flash CS4 IDE. I'm not sure what kind of animation would perform best (higher frames per second) in a game. Frame based or maybe use the motion tween, also would it be best to do say the motion tweens by calling a frame or by calling a method with the animation code in it? ...

why overloading not support in Actionscript?

Hi, Action script is developed based on Object oriented programming But why it is not support function overloading? Flex is support overloading? If yes, please explain briefly with real time example Thanks, Ravi ...

localy execute actionscript bytecode

i want to execute a piece of bytecode so that it will run in a specific scope ? for example i want to be able to run this code label.x = 100+label.width and have it react to a label instance that is somewhere inside the compiled swf. i want the code have the 'this' keyword of my abc code to point to the parent of the label instance....

Internationalization in Flex

Hi, Any one explain, how flex is support Internationalization and how to use it in flex mxml or actions cript? Please explain with example. Thanks, Ravu ...

StyleSheet.parseCSS converts style-names to lowercase in AIR

I am loading css file in Flex 3 AIR application. While reading the style name, I am lowercase version of it (i.e, .NewFontStyle is converted to .newfontstyle) how to get name as mentioned in css file. my code: private var prefsCSS:StyleSheet = new StyleSheet(); private function ReadStylesCSS():void { fileStream.open(appStorageDi...

Flex AIR Sqlite as embedded database

Hi all, I am devloping an editor with spell check feature in Flex + AIR using Sqlite as an embedded database. In database I have a table with the words. The table contains lacs of words. I have written the code to search for the word in table. I have used the sync method for all this. This pauses my application while searching. I would...

Rendering random curves with loops between 2 points

I need an ActionScript 3 library that renders randomized splines with a set amount of loops in the spline, and while I'm Googling, I was hoping someone could recommend some library that I could perhaps download for this purpose. Thanks in advance! ...

How to access parent movieclip's variable from loaded swf.

Hello, I have a swf which load an external swf. The loader swf has a variable which i want to access from the loaded swf. I use MovieClip(parent.parent).myVar but it return this error TypeError: Error #1009: Cannot access a property or method of a null object reference. at card01_fla::MainTimeline/frame1() The loader swf has...

Access the function object (closure) of a setter

Assume I have the following class: class Example { function set something(value:String):void { trace("set something"); } function doSomething():void { trace("something"); } } I can access the functions as objects like this: var example:Example = new Example(); var asdf:Function = example.doSom...

How to know if actionscript 1, actionscript 2, or actionscript 3?

I don't have a specific code sample, but is there a general way to guess what version of Actionscript the code snippet is: 1 or 2 or 3? I read somewhere that if it's code in the timeline, it's considered Actionscript 1. ...

Uploading video using the YouTube API via Flash AS3

Hi, I'm trying to work out how to upload videos to YouTube using the api from flash. There seems to be libraries available for doing this with php, ruby, java etc. but not AS3. Can anyone point me in the right direction on how to do this? Thanks ...

AS3 using a Matrix to "scale" an object from its "center"

Hi all, Here's something I'm trying to figure out concerning display objects in ActionScript3 / Flex. Let's say you have a display object who's registration point is in the top left and you want to scale it from its center (middle of the display object), How could you easily acheive this with the flash.geom.Matrix class Thanks for you...

Saving large images created in Flex

I am attempting to capture a very large image that was made dynamically within the Flash Player (the size of the image is 2400px by 12,000px) and am running into some very serious issues... Let me run down how the image get's to that size in the first place: User adds elements to a canvas and then when the user is finished the canvas sc...