I'm fairly new to using Flash, only one previous project to my name.
I'm an OOP programmer in other languages so using classes appeals to me and I want to use them in my next project. However I'm having problems after following tutorials on-line.
I've created a classes file called ScreenWordClass.as and within it is a very simple definition for this class at present. But when I try to use this class with say[code]...
C:alexflashportfolioimagesDualGallery.as, Line 15001: The name of package 'portfolio.images' does not reflect the location of this file. Please change the package definition's name inside this file, or move the file. C:alexflashportfolioimagesDualGallery.as
My class file is located here: C:alexflashportfolioimagesDualGallery.as My class file is defined as: package portfolio.images {.....
My FLA is importing it as : import portfolio.images.DualGallery;
Normally I use portfolio.classes and I have no trouble. My AS3 prefs are set to the alexflash folder.
I have a program where I have multiple classes derived from a base class. I want to take all instances of the different subclasses and put them into an array. Is there a way I can search for anything derived from the base class?For example, right now a get the number of children, then see what they are, so:
for (var i = 0; i < this.getNumChildren(); i++) { if (i is "type")
I have some experience working with Flex but im feel clueless working with flash pro. My problem is that i found a flash project that i want to edit (.fla), this project contain an actionscript class in some part that i am unable to find. How to find a class in Flash Professional?. I know that the class exist in the project because i generate a swf file and decompile it and it show the class.
public class Fruit extends MovieClip { //something } var apple:Fruit = new Fruit ();
[code]...
Is there a way to find the class of apple without using (apple is Fruit)? Doing it that way takes an array and having to check it with each index of that array to see if it matches.
I'll be working along on a project, using a Document class, adding new functionality, then all of a sudden I make a change in a class file, and my Root FLA can't find my doc class. Nothing has changed in my folder structure, I haven't changed my FLA or the doc class in weeks, but now suddenly I can't link to it anymore. I try changing the file names, and re linking, no luck. In the end I have to make copies of the entire project folder, rename things again, create a new .as file for the doc class and copy all my code into it.
I usually use if(object!=null) but it doesn't work well.
How can I verify if the class is instantiated. I want to get rid of the 'cannot access a property of a null object or reference'.
I mean, the 'var object:Object;' is just a reference to an Object class instance. When i initialize it with 'object = new Object()' it runs the code in the constructor, initializing it. How can I check if it has been initialized or not.
Ill be working along on a project, using a Document class, adding new functionality, then all of a sudden I make a change in a class file, and my Root FLA can't find my doc class. Nothing has changed in my folder structure, I haven't changed my FLA or the doc class in weeks, but now suddenly I can't link to it anymore. I try changing the file names, and re linking, no luck.
In the end I have to make copies of the entire project folder, rename things again, create a new .as file for the doc class and copy all my code into it.
when I create a new flash project, I would like to put the source files in /src/ folder.When I try to add the base class to my project, flash can't find it.I've added the folder "src/" to source paths, in flash preferences.
So I had a working .fla, with a document class package in the same directory. Everything was fine, until moving both to a new directory, now the fla cannot find the document class. WTF?
I have a App.fla file on a path and a App.as file on the same path. On the Class field I put "App" and on the ActionScript Settings Source path there is "." which means the same path of the .fla file, right? I open the App.fla file and click on the little "pencil" icon in order to edit App.as but then Flash whether tells me there's no class file associated or it opens a new ActionScript file.
So I can't do nothing , I even copied all code into the App.as , and pasted into the new ActionScript file it generates when I click the little pencil button. It still cannot find the god damned class. A little detail, I'm using Mac OS X 10.6.2. I've been working full time with flash on a Windows and that never happened to me before. That hasn't happend to me on Mac either (though I have hardly used it to do FLASH/AS).
I am trying to build my first flash facebook app, using the "flash facebook cookbook". Its instructions are all for flash builder and I am using flash pro. I've downloaded the flash facebook graph apk, and connected the swc, but when I try to login I need to return a FacebookSession object and I keep getting an error message that it can't find the class.
I import the: import com.facebook.graph.Facebook; But it's as if the swc connection didn't work.
im getting an error message that flash cant find the base class. i put the as file and the fla file in the same folder, isnt that the first place in the classpath?
All my custom classes that extend MovieClip simply trace as "MovieClip" when using stage.getChildIndex(i); I'm trying to search the stage to see what objects have been placed and then add them to the correct array. E.g. if I place 5 "Enemies" on the screen, I want to then add them to an array by searching the stage for the "Enemies" class, without naming each one and adding it manually in the code.
Using the mac version of flash CS3, and trying to import classes, namely the Loader class. Everywhere I've seen this code is used:
import flash.display.Loader; or for all classes in display: import flash.display.*;
Neither of which seems to work, and after searching out the file path for flash.display there is only one file in the display folder (BitmapData.as).So my question is, where do I find the loader class? And secondly, once I find it, do I copy and paste it into the display folder or do I use a different file path?
I have a fla that does a few things before loading in a .flv file and playing this. All this works fine, now comes the issue.
I have to find when the player stops.
I have tested around with cuepoints as well as many other options and found this code on these forums, where at least my flv file is played through, but the buffer throws an error[code]...
Yesterday I was working in an exhaustive animation when the computer turned off. When I turned the PC on again there was a message about a recovery file. I opened the recovery file: it was the animation I was working with. I finished my work and closed the recovery file. Today I was looking for the file I was working with and I can't find it: Flash gives me just the original file not the recovery file.
I am loading data from one sample.xml file using http service. the xml file will generated by jsp and it is saving in one proper location like(d:/programfiles/some.xml).now when I first time login to application i need to check whether that xml file is present or not. How can I check?
The problem is about the regular expression, how can I find this whole line by regular expression?
I am using the RegExp from ActionScript3
The main challenges are:
The <%@ %> instruction may contains another <%$ %> instruction in its attribute, just like the one above The <%@ %> instruction may have a line break in it, just like the following.
I am trying to build a .xml image scroller using the scroll pane component in CS4.I choose Actionscript3. Drag the component to the stage. Give it an instance name.Then I look for the Parameters that used to be in the properties panel in CS3. Not there anymore.I find that the Components Inspector has Parameters in there now.OK.I need to use ContentPath to tell the component where the .xml file is so it can find the images for the scroller.Can't find 'ContentPath'.How can I point the component to a .xml file?Is there a way of getting Parameters back in with properties - it was so much easier.
I have purchased an image gallery program that works fine but I am struggling to make a very minor modification. I have asked the author for assistance but previous requests have met with no response so I am also asking my question here. This program has most of its logic in an external AS2 file. I have made some small changes to this file and want to save it under a new name. However, that would also require me to change the reference to the external AS2 file from within the fla file. That's where my problem lies. I can't find any code in the fla that contains such a reference.
If I try to publish an swf without this file in the required location it causes a compiler error thus proving that there must be a reference somewhere to that file. However, doing a search for this AS2 file in the 'current document' when viewing the fla file in Flash CS4 produces no results. Where else could this reference be hidden?
I have made a simple copy file in php that when I type in a name in my swf it saves a swf file that I have already created. But what I want is to beable to pass my vars to this swf -- but the only way I can think of is to say if(active file name == myxml.value[x]){do this} I don't even know if this is an option or a good solution but is there away that flash can find the active file name.
I have a symbol being loaded in through my XML file and its not being displayed. I am using Verdana, I have characters embedded and Ive even tried adding � to the include these characters section and still no luck.
Im working on a project where files are being loaded using the URLloader in flash as3. I need to be able to find the last modified date of the file that is being loaded, unfortunately the files may not always be on the same server as the flash app, so it may not always be possible for me to add a line to the file that has the last modified date, that could be read easily in flash. I was wondering if anyone knew of a way to retreive this information, I know in air you can use URLLoader.httpResponseStatus which allows you to get the http headers and find it that way but it doesnt appear to work in flash.Id like to try to do this with out having to call on javascript or php to find it, since it would then require 2 connections per file i believe to be able to do everything I need 1 to get contents in flash, and one for either javascript or php to find the last modified date, but if I have to that seems to be the only option I can come up with.