actionscript-3

AS3 Array Problem

[Bindable] private var arr_activities:Array; var test: _Aktivitaet; arr_activities = event.result as Array; test = arr_activities.pop() as _Aktivitaet; Why does test always stay null??? _Aktivitaet is a custom class: package at.moschitz.topfive { [RemoteClass(alias="Aktivitaet")] [Bindable] public dynamic class _Aktivitaet ext...

Is it possible to call external movieclips' function or passing data

Assume I have 2 swf. first one I have a method on the first frame function methodA():void { } Second one will use the loader class to load the first one and use that to call the methodA. I wonder is it possible to do that... What about passing data.... I am abit too poor in AS 3.0 , I can pass the variable and call function from ...

A way to programatically generating background with ActionScript 3.0?

I am connecting to an XML back-end to create different "pages" for a flash website. (I know.) And I'm wondering if there is a way to programatically generate a background that will automatically be the correct height for the content within each "page". My background is in the form of a seamless tiled graphic. Is this even possible? ...

create dynamic navigation from xml file in flash cs3

action script newbie here :-) What I want to do is this, hand an xml file to a swf and have the swf generate a dynamic text box and button for each of the links in the xml file a rudimentary navigation here's the xml <?xml version="1.0" encoding="UTF-8"?> <page> <page name="Page Name 1" url="/page-1/" /> <page name="Page ...

Changing individual TextArea/TextEditor lines in Flex?

So for a summer project I am thinking of writing a colaborative code editing application in Flex. In order to do this I need to be able to modify individual lines or characters in a text area as different user's modify the same document. I think I've heard of Flex 4 having support for text primitives but that is still in development. I...

Writing a syntax highlighter

I was hoping to write my own syntax highlighter for a summer project I am thinking of working on but I am not sure how to write my own syntax highlighter. I know that there are bunch of implementations out there but I would like to learn about regular expressions and how syntax highlighting works. How does syntax highlighting work and ...

Why can't I access xml nodes with out namespaces?

I've been banging my head on my desk for hours trying to figure out why I can't access the entry.author.name content? I've tried every possible way to access it but failed. But when I loop through all nodes with xml.children I see the author node. I see the author node is apart of the atom namespace but it doesn't have a namespac...

Flex :: <mx:transitions> not working Properly in my flex project ?

i used <mx:transitions> <mx:Transition fromState="*" toState=""> //universal_title name for TitleWindow id another stage .loginform is panel id another winidow <mx:Sequence targets="{[Universal_title,loginform]}"> <mx:Sequence id="sequence1" filter="show" > ...

AS3 retrieving xml from aspx page

Hello all I'm an AS3 noob on training wheels... I have an XML Loader class which is doing what it's supposed to with a test.xml file, however I need the flash to read the xml written by an aspx file. So I tried: var urlRequest:URLRequest = new URLRequest("../xml/CaseStudyFlashAssets.aspx"); I get error #1090 (which I gather is bec...

Reading XML In Flash From An ASPX Page

Hi guys, I have created an aspx page which dynamicaly creates an xml string and posts it back to the client. protected void Page_Load(object sender, EventArgs e) { Response.Clear(); Response.ContentType = "text/xml"; Response.ContentEncoding = Encoding.UTF8; var flashAssets = Asset.GetScro...

How to Auto-resize font size to fit text box height / width?

I am trying to have text automatically size its font to fill an entire text component. My current approach is to set font size as a function of the number of text characters and the text components height and width but I can't find the right coefficients to make this work nicely. Is there a simpler or more elegant way? Does truncateTo...

AS2 Buttons to AS3

How do I convert these AS2 Buttons to AS3? on (press) { nextFrame(); } on (press) { prevFrame(); } ...

Is it possible to access static fields declared in a host application by movies loaded dynamically using SWFLoader

Is it possible to access declared static fields in a host by a dynamically loaded movie (provided the loaded movie is from a fully trusted domain). My main concern is to make sure we don't expose data to loaded swf's, but want to still listen to events (via hosted apps callback functions) fired by the loaded swf. UPDATE SWFLoader (f...

How do I wait for an external .txt file to load in ActionScript 3?

How do I wait for an external .txt file to load in ActionScript 3? If I use URLLoader, I have no guarantee that the file has loaded, since it dispatches an event when it's complete. I'm calling the loader function from another class, so I can't simply stick the next actions into the event listener. ...

Do you know any example about system tray application using air or flex?

I made one small application using flex . it is working correctly but i want that application icon show on system tray .how wiill i do for that ? i used if (NativeApplication.supportsSystemTrayIcon) { NativeApplication.nativeApplication.autoExit = false; icon.contentLoaderInfo.addEventListener(Event.COMPLETE, ...

When an swf (or other external remote resource) is loaded using SWFLoader, is there any client side caching performed.

Would like to know if when an external remote resource (say SWF, or JPG) is loaded using the SWFLoader (or even Image component) in flex3, if there is any client side (ie. browser caching?) or the loaded resources. In particular would a second request then to access a previously accessed resource just use the cached resource or would a ...

How can I make my entire flex widget have rounded corners?

I am creating a Flex widget and would like to make the corners rounded. In other words, I don't want some component inside the widget rounded, I want the actual widget to be rounded. I have seen this done in many places so it cannot be too hard, but all of the solutions I find on the internet do not work. People say to set the corn...

Is there a way to override action scripts operators, in particular I would like to override the equals operator

Is it possible to override the equals() operator (ie. for customer classes where equality may be determined by 2 or more fields matching). ...

Usage of generated Actionscript proxy enum from C#

Sorry if the title is unclear - not sure how to phrase it. Feel free to edit it. I have a web service written in C# and it uses an enum. When I am consuming this webservice with Flash, I had Flex generate the proxy classes - which also generates said enum in Actionscript. My problem is that I don't know how to use this generated Actions...

auto update in flex application

I am using auto update in my flex application using the updater framework. I got this article and followed the same steps. http://blog.multimediacollege.be/2008/12/using-the-air-15-updater-framework-in-flex/# But i'm getting an error and can't understand the reason: 1046: Type was not found or was not a compile-time constant: Upd...