Actionscript 3 :: Swf File Can't Read Data From Config.xml File In The Same Flex Directory
Feb 28, 2012
I have a main swf file and config.xml located in the same directory. My .swf file uses config.xml to fetch config variable which it does with success.The problem appears when I put those files into Flex directory. I embed .swf file like this.
<mx:Image id="loading" source="@Embed('/blobs/visualLogo/mySwfFile.swf')"
visible="true" horizontalCenter="0"/>
I also place config.xml into /blobs/visualLogo/
This time I get an error in Flex:
TypeError: Error #1009: Cannot access a property or method of a null object reference.
at mySwfFile_fla::MainTimeline/frame1()
View 1 Replies
Similar Posts:
May 21, 2011
I have a flex application which contains different feature that includes google maps, twitter, facebook etc.
Currently I have hardcoded api keys in the code it self but I want to use a properties file/config file where I can put such things and use anywhere I want in the application.
Is it possible to achieve this in flex? I am using swiz framework. Is it possible to achieve this using this framework?
View 3 Replies
Mar 19, 2012
i'm trying to perform simple automated test on my Adobe Air Application. I decide to store some test data in external MS Excel file to decrease hardcode quantity. But I discovered, that this is not a trivial task, when you're working with Adobe Air.
Actually, i need to correct initialize an excelApp object, the rest part of logger is already implemented. I tried the following approach, but I can't find a package with ActiveXObject class defined.
excelApp = new ActiveXObject("Excel.Application");
View 1 Replies
Aug 31, 2009
I need to read data from a file after a user has selected a file using a file browser, for a Flex web app (NOT AIR). I know this is possible in Flash 10 using the FileReference class load and data methods. But using Flash 10 is not an option for me. So does anyone know of anyway I can do this in Flash 9?
View 0 Replies
Jun 4, 2010
what I meen is to get all objects and their properties, is it possible? How to do such thing?
View 2 Replies
Mar 29, 2012
I'm using Parsley in my flex mobile project. I have multiple destination services but I can't find more resources on how to add another destination service to config.xml file. The file is as below:
<objects
xmlns="http://www.spicefactory.org/parsley"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.spicefactory.org/parsley
[code].....
View 1 Replies
Mar 29, 2011
We can auto-generate flex-confix xml file from flash-builder so to provide users that want to compile project on there own would be capable of doing such thing with out buying FB. So we use something like -dump-config slotConfig.xml as flex compiler argment. This generates a file for us... with lots of detailed comments like this one I generated from that project:
<flex-config>
<!-- benchmark: output performance benchmark-->
<!-- benchmark usage:
[Code]....
View 1 Replies
Mar 31, 2010
A friend of mine has a Flash Action script running on a LAMP server that currently reads an xml config file. He's asked me if it's possible to remove the xml file, and replace it somehow with a system (lets call it an 'auto xml generator') that intercepts the request to read that file and generates an output, so it appears to all intents and purposes as if the file still exists and contains the contents that has actually been returned from our auto xml generator'
View 3 Replies
Feb 9, 2010
When I have a class linked to a MovieClip in my library and that class takes an argument in its constructor method. That class will compile properly ONLY when it's located in my top-level directory (same dir as the .fla and Document.as files). If I move that class to a deeper directory, say com.place, and update the package statement and symbol link appropriately, the compiler will generate error "1136: Incorrect number of arguments. Expected 0."Create flash project and put a rectangle on the stage. Covert it to symbol and assign it to class TestPanel - or whatever you choose. Also configure the fla so that is uses a Document (Main) class.Create Main.as and TestPanel.as in the same folder. In the Main class, instantiate a instance of TestPanel and add it to the stage. Flash will, predictably, add the rectangle symbol and everything is fine.Now modify TestPanel so that its constructor method takes a Number and have Main.as pass some number to TestPanel.[code]You now get the error: 1136: Incorrect number of arguments.Expected 0.When I move the TestPanel.as into a deeper directory, Flash somehow is looking elsewhere for the base class for Symbol, even though I'm mapping that Symbol to com.place.TestPanel.
View 4 Replies
Jun 10, 2009
I want creating an interactive cd rom using xls file, is it possible to read data on an swf animation from an excel file?
View 5 Replies
Nov 19, 2009
We are writing log files to File.applicationDirectory and want to clean out old log files. The question is how do you delete files out of that directory? When I try and delete old log files out of this directory it gives a security exception. Is there anyway around this? I know you are not supposed to write to File.applicationDirectory, but we are writting are logs there anyways.
View 2 Replies
Dec 28, 2009
how to write a file to File.applicationDirectory in flex. i am getting security filewrite resource error.
View 2 Replies
Oct 26, 2010
I have trouble getting it to copy file from src to destination.
var asMsg_path:String = fileRef.nativePath;
var origFileLoc:File = File.applicationDirectory.resolvePath(asMsg_path);
var newFileLoc:File = File.applicationDirectory.resolvePath("/java/"+asMsg);
[code]....
View 1 Replies
Sep 27, 2010
I have two variables that I would like to store in a remote data file which can be accessed by my Flash file. It is for a voting system, so the first variable would be a counter that is incremented each time a user votes, and the second would be the total rating. The average rating would then be calculated from these.
How would one store, retrieve, and then update these variables from the data file?
I can create the system within a single Flash file for a single session, but obviously I'd like multiple users opening the file simultaneously to be able to access the data and update it.
View 4 Replies
Aug 11, 2010
I am creating an AIR application using Flex. In it I use a file in application directory to store some data in it.Its working very well to read and write data to this file with various OS except windows 7. In windows 7 it is not working. May be its a permission problem.
How can i write file in the application directory with Windows 7 ?
View 2 Replies
Apr 15, 2012
package com.func {
public class Downloader {
import flash.net.FileReference;
[code].....
View 1 Replies
Feb 23, 2011
I am writing to an XML file which is placed in the src directory of my Flex project. But when I run my application, the changes I make to that XML file actually reflects in the copy of that XML file in my [code]Is there a way to reflect those changes to the actual xml file i.e. the one in the src directory?Server Side: PHP.PHP file is in the same src folder. Here is the related snippet of code:[code]
View 1 Replies
Jan 18, 2010
I wanna read a text file data and show them in a textArea.
View 1 Replies
Aug 21, 2011
i'm trying to make a Top Score history for a flash game, which i load from an XML file. The problem comes to when i want to update the XML file. how do i do that automatically without prompting the user (ofcourse). I want it to be saved automatically to the same directory as the flash file.
here's my code right now, but it prompts the user where it wants to be saved, which i don't want to happen:
var xml:XML = <XML>
<topScoreList>
</topScoreList>
[Code]....
View 5 Replies
Sep 16, 2010
I'm trying to build a flash component for my upcoming website where I have to read data from a XML file and show these with a fading 5 second interval - I guess you could call it an image-fader/content-fader or some such :-) Before I post my code I would like to let you know that my experience with AS3 is quite limited as I've always been working with Silverlight (C#) instead.
[Code]....
View 1 Replies
Jan 6, 2011
I want to create music Visualization in flash by reading the musicXML file.Is there some sort of a class that reads it? or a help guide to understand the musicXML structure and how to use it in order to visualize its music?
View 1 Replies
Dec 30, 2010
Is it possible to use flash to read and write data on an excel/google documents file?
View 1 Replies
Jan 25, 2007
I need to parse and display the value for variable VALUE in xml to the screen but read from the file continuously instead of
once. The XML file is being created dynamically so its getting larger but flash only displays first value for variabel VALUE.
View 5 Replies
May 11, 2011
I have a photo gallery with a navigation button that allows for additional photo categories that I don't want to appear. Unfortunately, I can't open the .fla as it appears to have been created with a newer version of Flash. The code in the config.xml file is basically:
<navigation> <menu 1> <content>
</menu 1>
<menu 2> <content>
</menu 2>
etc.
</navigation>
Is there a tag I can add to make the navigation link disappear?
View 5 Replies
Nov 23, 2010
Is there a way to set the value of a private static const identifier from a config file during compile time in Actionscript 3?Also, it would be nice if I can do this in the mxmlc ANT task.
View 2 Replies
Mar 31, 2011
I've got a flash file that reads some links from an xml config file. These links look like:
<url target="_blank" method="GET"><![CDATA[http://www.google.com]]></url>
Instead of a link, I'd like to call a javascript method that opens up a modal dialog with a list of items. I've tried the following based on some things I found, but I can't get it to work.
<url target="_self" method="GET"><![CDATA[javascript:loadAsModal(#modaldiv, ajaxmenu.jsp?gid=3)]]></url>
and
<url target="_self" method="GET"><script type="text/javascript"><![CDATA[loadAsModal(#modaldiv, ajaxmenu.jsp?gid=3)]]></script></url>
loadAsModal() takes in an empty div that i put on the page, and then the menu.jsp which builds the menu given the group id. I made sure to import all of my js libraries on the page.
View 1 Replies
Jul 14, 2011
The flex compiler (mxmlc) allows the use of token substitution in the compiler config xml file, as referenced in the documentation.From the linked documentation it is clear that you can specify your own tokens for substitution on the commandline, but there are also some default/magic tokens available that Adobe has put in place.For example, the snippet below is reduced from an Adobe example on how to fiddle with the framework RSL sourcing:[code]I have highlighted two tokens in use there, namely hosted.rsl.url and build.number. These work "magically" without specifying them on the commandline.
Here is another example that vaguely shows the existence of a ${flexlib} token.Unfortunately, aside from those limited examples I can't find a whisper of documentation on what tokens are available... Is the list of tokens documented somewhere that I can't find? If not, does anyone know what the available tokens are so that this SO question can be the documentation? referenced build.number, I might as well also note that build.number doesn't seem to work quite like Adobe seems to think it does since for me it simply gives me the build number, not the whole string. ie: For flex 4.5.0.20967, ${build.number} just gives me 20967 which is not much help). I had a web link where someone was complaining about the changing implementation of these tokens, but I can't find it anymore.
View 2 Replies
Sep 9, 2006
If you have an .as file in the global include directory do you have to upload it to your server with the flash file or does it compile the flash file with the included info?
View 2 Replies
Feb 7, 2010
I want to read an xml file placed in the same folder as the swf. Note however there is no webserver running.
<![CDATA[
private var my_req:URLRequest = new URLRequest("assets/GmetadOutput.xml");
private var loader:URLLoader;
public function startup():void {
output.text="CheckPoint1"; //This is the only output that displays!
[code]...
So on the on CreationComplete event i call startup(); The Checkpoint1 output displays but none of the other checkpoints are reached? how to read a file placed in the same folder as the swf file!
View 2 Replies
Feb 9, 2010
I write object in a file. first i convert the object to bitmap data then i write it in a file. Now I want to read object from the file so that it returns the original object. How can i do this?
View 1 Replies