Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    Flash




External Import File Does Not Work Perfect :(



Hi all,

I have a question (DOPE...DUH...no your kiddin me )!

I made a site in Flash. The site load some external files and that works perfectly...well allmost then!

One of the external files (#1) get loaded into the side perfect BUT...in file #1 i've got a movieclip that contains some buttons.
All of these buttons are connected to another movieclip (movie1).

If I run #1 and hit the buttons, it load movie1 like it should be. BUT...if I run the site movie and press the button that must load #1, it runs #1 perfect except the movie1 when I press the buttons in #1!

The actionscript from the buttons in #1 to load movie1 looks like this:

on (release){
getTarget ("/movie1"){
gotoAndPlay("2"); //the number is differend with each
button
}
}

I hope I made myself a bit clear seen the fact my English isn't that good !

Thanks,

AmunRa



FlashKit > Flash Help > Flash MX
Posted on: 02-27-2003, 03:15 AM


View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread

Import External Array, But... Doesn't Work.
Hello all, I'm new to actionscripting, but I have to do some hard things such as this importing values from an external array to an array inside flash. I tried many tutorials but none of them works. I tried a lot and found out the data although is imported, but I have no idea where they are stored. I need to utilize the values in later frames.

I think the values are stored in qArray, but when I traced the qArray even in the myVars level, it returns undefined. I tried very hard to debug but I'm very new to actionscripting in Flash. please offer advice and solution... thanks.

FRAME 1 :


ActionScript Code:
var qArray:Array = new Array();
var myVars:LoadVars = new LoadVars();
myVars.load("input.txt");
myVars.onLoad = function(success){
    if(success){
        qArray.split("###");
        trace(qArray.length);
        for ( z=0; z<qArray.length; z++ ){
            //loadVariables(qArray[z], "_root");
            trace("YES");
        }
    } else trace("FAIL!");
}

Frame 50 :

ActionScript Code:
trace(qarray[0]);


OUTPUT :

ActionScript Code:
Level #0:
Variable _level0.$version = "WIN 7,0,14,0"
Variable _level0.aArray = [object #1, class 'Array'] []
Variable _level0.myVars = [object #2, class 'LoadVars'] {
    onLoad:[function 'onLoad'],
    qarray:"1###2###3###4###5"
  }
Variable _level0.z = 0

Import External Text File
Hi All,
This is my first post after having read through many useful postings here, which have helped me to make a dynamic image gallery.

Now I need to add discription to each picture, so here is what i am trying to achieve:

I want to import discription for 16 pictures from an external file, intead of having 16 text files and importing each one individualy, I would like to have just one file with 16 discriptions and import that into my flash SWF.

Unfortunately my knowledge of XML is not very good. Can anyone point me in the correct direction ???

Is it possible to achieve the same result using just one Text file or would i have to use XML ??

Thanks

Cai I Import Images & Audio From External File
hi all

want to ask if i can import images or oudio to my swf file from external file

the important thing i want to know is

will the swf file will be smaller in size and loading ???

and how to load the soud from external file for a flash card

what about the preloading scene will it count the audio ??

because i want to have the smallest flash card size

Import External File To Then Pass Data?
I want to import a .txt or .xml file (so it's real text) that has a form on it. I also want to style the text on this form (will this real text be affected by the html's css or do I have to state it in flash? I also want to pass that form information to another scene, at which point the user will add their email and name and *then* click "submit".

Any good advice?
I do this all the time outside of flash but this is the first time I've done it in flash.
Any links/tutorials/advice is appreciated!

Is It Possible To Import Dynamically A Video Or A Jpg From An External File?
Hello everyone I am new in this forum and write because I don’t really know the virtuality of actionscript.

I would like to ask if it is possible to make a swf in which the user will be able to import dynamically a video or a jpg from an external file, but not from a specified one (like with loadmovie). I mean that the user will browse the pc files and will chose what he wants to import in the swf. I want to make a swf which works like a software. The user will import a jpg, write, draw on it, save it, and the next user will be able to continue his work (like a work in progress). Actually for me something like this seems impossible, because I am not advanced in actionscript, but I would like to know if this is possible at all. I just know how to write some small pieces of code, and I know almost nothing about programming. But if there is a way Please give me some key words or some references in order to start learning the how to.

I hope that makes sense because I am not very good in English

Thanks a lot

Import MovieClips/Classes From External File
Hey All,
I'm working on an OOP/Class based application. In order to save on filesize, I have some of my assets in another swf file, with their linkage properties set to classes that give them properties and actions:
Class: src.BLNavStation_Circle
Base class: flash.display.MovieClip

Special Charachters To Import And Display From External Txt File
I have a movie that reqiures text to be loaded from external txt files and then animate (simple animation). I am using loadvarNum and almost all text is displayed perfectly and animates fine.

The problem is I have in the text documents the +. I know this used to be used to indicate a space in text imported from a text file. I do not have any quotes or other + so I figured this would just display as another character. I was wrong!

I have a textbox set to variable main. The text file looks like this.
I've set the textbox to veranda font and embeded the font as well. (I've tried with _sans and no embed as well no joy !)
main=The equation you should use is x+y

I've tried
main="The equation you should use is x+y"
main=The equation you should use is x u002B y
main="The equations you should use is x"+"+"+"y"

Any ideas?

[MX04] External Data File To Import Variable To Array
Hello,

I have managed to load a variable "movies" from an external ".txt" file but there is a lag before it shows up. The code is:

PHP Code:



loadVariablesNum("data.txt", 0);




Then, I've got a code where I need the loaded variable "movies" to be used as a component of a for loop.

PHP Code:



//new array
arr1 = [];
//create entries with number of entries as required
for (var n=0; n!=movies; n++) arr1.push(n);
trace("before sort - "+arr1);




If I declare the variable outright (i.e.movies = 10) the second part also works; I just can't get the loaded variable in there. Any suggestions?

Rollovers Don't Work In External Swf File
i have an swf file that has images appear on rollovers of invisible buttons. it works fine on it's own.
when i play the main flash movie and this particular file loads, the rollovers no longer work.

the rollovers are all coded like this:
on (rollOver) {
_root.near1.gotoAndPlay(2);
}
on (rollOut) {
_root.near1.gotoAndPlay(6);
}
and the actionscript is on invisible buttons.


in the main movie, i am loading the external swf with this code:

on (release) {
loadMovie("repertory.swf", "holder");
}


any ideas why the rollovers might not be working?
thanks.

External Text File - Getting HTML To Work?
Hi there.

I have an external text file and it works fine but its just outputing the tags as normal text.


Code:
safetyFeatures=one line of text <br> We call it ZX Class Stability . It's <br>


I have the dynamic text box selected and html tags box is checked

Its just not reading the html tags

Its in Flash MX 2004..

Thanks.

After Upload; .swf Won't Load External .txt File? Somebody, Work Your Magic
hi there,
i've just about had it with this::
so i loaded "paranines.swf" and "contents.txt" to http://paranines.50megs.com/

i used: loadVariablesNum("contents.txt", 0)to load the .txt file
BUT IT DOESNT WORK...
i tried replacing ("contents.txt",0) with ("http://paranines.50megs.com/contents.txt",0) but the .swf still won't load in the text instead naming it "relatively"; all my variables are named correctly.

everything works perfectly when i test it from my computer.
as soon as i uploaded it to the site, it read the swf but the text wouldn't load.

im lost.

ALSO:: what about "GET" and "POST" what are they and would they help load the variables.

it's just a website for my band, but im soo frustrated,
i'll attach the .fla and .txt if anybody wants to work their magic.
im a flash newbie, don't make fun of the site

--zach
zbodtorf@aol.com

Callback In Dztween Doesn't Work Properly In External .as File
Hi

I tried to callback after a tween function(from dztween.as) finishes and it doesn't work properly.

1. Include the scope directly, but the global variable "f" is not updated.


Code:
class Test{

var f:Boolean = false;

public function Test(){
rect.tween(["_x", "_y"], [x_position, y_position], 1, "easeOutCubic", 0, this.move_finished);
}

public function move_finished():Void{
f = true;
}

}
2. Include the scope inside {}, but move_finished() is not called at all

Code:
class Test{

var f:Boolean = false;

public function Test(){
rect.tween(["_x", "_y"], [x_position, y_position], 1, "easeOutCubic", 0, {scope: this, func: move_finished);
}

public function move_finished():Void{
f = true;
}}
2. Include the scope inside {} and put the "()" after function name, f is updated instantly without waiting for the tween to be finished

Code:
class Test{

var f:Boolean = false;

public function Test(){
rect.tween(["_x", "_y"], [x_position, y_position], 1, "easeOutCubic", 0, {scope: this, func: move_finished());
}

public function move_finished():Void{
f = true;
}}
Any help would be really appreciated, thank you in advance

Loading External HTML File Doesn't Work With All Browsers
I'm loading an external HTML file (it's valid and all, has doctype, and meta tags if that matters) into flash. I've attached the code that does the loading. When it's loaded locally, it always works, but when it's loaded from the Internet, it doesn't always work in all browsers. Safari seems to work all the time, Firefox can be a bit fussy about it, and Opera seems to have problems. When I say it doesn't work, I mean the text doesn't get loaded, so the area where it should be is left empty. Is there any other way I can do this? It seems that if I put the text in flash, it has to be on one line, which is very annoying. The formatting gets screwed up if I do this too.









Attach Code

var loadVarsInstructions:LoadVars = new LoadVars();
loadVarsInstructions.onData = function(htmlInstructions:String):Void
{
instructions.htmlText = htmlInstructions;
}
loadVarsInstructions.load("instructions.html");

Launch Windows File Browser For Jpeg File Import To Flash?
I would like for the users of my interactive piece to be able to click on a button which says, 'import file'. This would launch the usual windows open file browser window to appear. Then the user could import an image file. This file would load into a holder movie clip and then would stretch or shrink to fit into a size of my choosing, i.e. 400 x 300. Is this possible? I imagine it might be using flash to call some javascript but I could use some advice.

Thanks

Import Mp3... Wont Work..
so, i keep trying to import an Mp3 into my library... and it says its
"working..." but then it doesnt end up in my library... huh..

anyone know whats goin on?? im trying to make an audio player.. i
want it to play mp3's... never done it before, but i think im on the
right track

jason

What File Extension Of Picture File Can I Import In Flash
dear all flash addicts,

i should find the answers myself but i dont flash anymore.
can someone tell me what picture file(file extension) i can import to flash?
i guess its different in ver of flash?
thanks in advance for your detailed reply.

best regards,

Import *.eps (from Freehand) Doesn't Work
I've just created something in freehand and when I try to import the file...........NADA. Some format problems. The file it' ok. If i check it with photoshop or other programs it works.The MX just won't do it.
THANX

How Do I Import SWF With Action Script And Have Them Work
Hi!

My inicial idea was to creat a sort of background flash movie and then load other swf's on to the stage as needed .. but (there is always a but...) when I import the first SWF into an empty movie clip it doesn't preform as expected, or should I say doesn't preform at all.

this "external SWF that I'm talking about is a 1-frame video clip that loads information based on a XML it also has a couple of movieclips that play according to the information retrieved.

after searching this forum I tryed a "solution" (that was typing "_lockroot = true" on the first(and this case only) frame but that was pointless.

How can I accomplish my Idea without having to remake(copy/paste) the external swf into the main swf.

note: I have the FLA files of both SWF's


Thanks in advance,
Zmei2005

Import Of Simple Movie Does Not Work
I have created a simple movie. When I try to import it into another movie. It does not work?

The code is at this url.

http://www.mindspring.com/~lhudspeth/wheel4.html

Flashpaper SWF Import Doesn't Work?
Hope to gawd I'm wrong...but it appears you can not import a flash paper 2 swf into a flash document?

Web pages only?

This would be disappointing. I looked through the tutorials and all, they never reference directly importing a Flash Paper swf into another flash doc. When you try it completely collapses.

File Import / File Size Question
Hey everybody,

little question...i have to quicktime movies here...one is the animation itself...the other is the alpha channel of that animation and want both of that in flash...

Now what i did was compositing those anims in after effects, then exporting as a series of tga's (with alpha) then importing in flash...

the problem is that the swf explodes from around 600kB to 2.1 MB...now there must be a better way of doing this...Do flv's support alpha, if yes, how???

Greetz

Movies Don't Work When I Import Them To My Invisible Movie Clip
How come when I load a movie into my "invis_mc" it stops working? If the movie is alone it works fine. I have attached the fla files. contraPractice.fla is the home page and I get the problem when I click on the buttons Band or Media. If you run slideshow.fla or bandScrollText.fla they work with no problems. I believe it's an actionscript issue but I can't figure it out.

Please help.

Sandra

You can visit the website at contrabandjams.com (I am using work arounds because of this issue)

Export To *.txt File, Import Same *.txt File
i searched the forum and came up with nothing. i want to make an input text field where i can type new info for my page (in a password protected area) and then when i click the submit button it will save it to a txt file. after this i am going to have the txt file loaded into a dynamic text field where it can be read by everyone. i know how to use the loadVariablesNum("bla.txt", 0); function to load it. and where the text file has to have the textField= part at the beginning to be able to load it into the page, its the exporting it to the txt file that i am having trouble with.

The Best Way To Import External Txt
What I'm not sure how to do:
1. Take external text strings from PHP
2. format them to have links styles, classes (currently used in my HTML ver)from my external CSS

I just dont know how to convert an entry like below into a flash textfield. I am currently using PHP to build an HTML document with my CSS tags. Whats the best means of doing this?
I cant figure out the hover state equiv. in a textfield either.


I have only brought text that wasnt dynamically created and I don't want to mess this up for the future.
Here one section of whats to be many successive 'section's. Having control over the background, font and color of each section would be ideal.

HTML Code:
<div class="linkSection">
<div class="linkHeader">Glossaries of Graphic Design, Printing, Typograpy, Cutting, Numbering, Binding, Embellishing...</div>
<div class="linkSectionDesc">
<p>Terms, standards, diagrams and goodies crucial to our fields explained in great detail.</p>
</div>
<div class="linkDesc">
<p><a class="linkName" href="http://home.vicnet.net.au/~typo/glossary/theme-m.htm" target="_blank">Melbourne Museum of Printing</a> - Printing and Typography Glossary that includes many finishing terms.</p>
<p><a class="linkName" href="http://glossary.ippaper.com/default.asp?req=knowledge/article/216&catitemid=32" target="_blank">International Paper</a> - This glossary for printing includes great colored diagrams of much of the printing and finishing process.</p>
<p><a class="linkName" href="http://www.printindustry.com/glossary.htm" target="_blank">Print Industry</a> - Glossary of Printing & Graphic Terms - Important terms of the industry alphabetized.</p>
<p><a class="linkName" href="http://www.expertsinfinishing.com/folding.html" target="_blank">Finishing Experts Group</a> - Check out the great overview of folding basics.</p>
</div>
</div>

Import External Swf
Is there a way to import/include an external swf into a fla and give it an instance name?

Import External Swf
hey people - this should be a breeze for most of you. i have two flash projects and want to incorporate the one into the other. ive tried this by importing the swf but this breaks the flash project down and removes the action script. how do i import a flash project and keep the project intact in the mean time?
a.

Import External Swf
hey people - this should be a breeze for most of you. i have two flash projects and want to incorporate the one into the other. ive tried this by importing the swf but this breaks the flash project down and removes the action script. how do i import a flash project and keep the project intact in the mean time?
a.

Import External Video?
Hello
1. How to import external video files into flashMX (ie loading jpeg using loadMovie).
2. How to control external video files inside flash MX

The video file size is around 200 MB and the client updates the video file frequently. Hence interested in loading external video files

Import External Picture?
im making a site where I want to load pictures in to the site, is it possible and how? it should be loaded like variables are loaded from a .txt-file.
the pictures should often be refreshed, but I don't want to upload the entire site again and again... and uploading a new .swf that would be loaded with loadmovie, will not be the best solution either.
thanks in advance
-hashmus-

Import External Code
I am making many different flash movies, but with almost the same code. So, I would like to have external code that all the flash movies "read" from. So, if I change something I won't have to change all 100 movies.

1. is this possible with flash?
2. How is this done? (include?)

I have flash 8 pro. Thanks.

Import External Swf Vs. Add Children
This is going to be a more self feeding survey for the most part, but I'm interested in what experiences people have had in this department. I'm working on a site right now which has given me a chance to experiment with, and hone my object oriented as3 skills. In the past, I would import external swfs to build a site. I've abandoned that for adding and removing children to help with memory management. I've seen some quirky thinks happen with this new model of adding and removing children. I'm ready to redesign the site to go back to loading external swfs. Let me know if you've come to the same conclusion.

Here's the site i've been working on (work in progress). www.seanpauldesign.com

It's lagging really bad in safari.

Hope everyone's new years is good.

Import External Sound?
How can I import and play external sound from a URL on the internet? I know how to import it from the library, but I need to import it from online.

If you can help, thanks.

Here is the sound file I made:
http://shirow-section9.com/audio/shirowtheme.mp3

Import Flash.external.*;
Have a flash project originaly developed in Flash 7.
I now am working on the this project in flash 8 IDE.
When attempting to use the external API; import flash.external.*; presents a syntax error when attempting to debug / publish the project, yet projects developed in flash 8 do not present this error.

THOUGHTS ??

Import.flash.external
have a project originally developed in flash 7.
I am now working this project in flash 8 IDE.
When I attept to use the external API (import.flash.external.*) I get a syntax error when attempting to debug / publish.
Other projects developed in the flash 8 IDE work fine w/ the external API.

THOUGHTS ???

Import Data From External XML
Apologies if this has been covered already. Using Flash Pro 8. Trying to generate movie clips dynamically from data in an external xml file, but having a miserable time getting it to work. Here is a stripped down example of what I have.

My .xml file "PigParts.xml" contains data in three cels:
A1: Ham
A2: Bacon
A3: Chops

How do I get the data in the .xml into Flash as a string/array? I have been trying some stuff, and going through the AS Bible, but have had no success. The attached code is where it's at right now.







Attach Code

var xmlVal:XML = new XML();

xmlVal.load("PigParts.xml");

xmlVal.onLoad = function(bSuccess:Boolean):Void{
if (bSuccess){
trace(this.toString());
}else{
trace("Document failed to load or parse.");
}
};

//This trace returns:
//<?xml version="1.0"?>

stop();

EXternal Import Question
Hello,
I have a small problem with an external SWF being loaded into a Main SWF. The file loads fine when called upon, however the links on the exteranl SWF stop functioning. The cursor detects that the link is there, but the links do not work. The links are just for text scrolling in from the left, nothing major.
Any help would be great!
THanks
DAve

EXternal Import Question
Hello ,
I have a website I'm working on, and in the middle of the site I have an empty movie clip which is the holder of external SWF's. This is where my content is going. My menu on the first page calls the external SWF's to that location fine. When the SWF is in place, the rollovers on the SWF do not work. THe icon comes up that there is a rollover or button there, but nothing happens.
Plus when the site first come up, I have a script for the first SWF to load on entry, but when I preview the site in the browser, the SWF does not load.
Any help would be appreciated.
I know these forums are a jewel.
THanks
DAve

How To Import A File?
I know this is a message board for flash users and I am one but my question is, how do I import a menu that I created in fireworks 4 into dreamweaver? I am creating a page using flash 5, dreamweaver and fireworks 4 components and I cannot get my menu to show on my page in dreamweaver. I don't know where else to turn for an answer. Can anyone help me?

Import .avi File
How do I import a .avi movie file? I tried plain old import in Flash. Although the movie worked when I played it on the timeline it didn't show anything when I published it or tried to preview it. Thanks in advance

How To Import A .swf Into A .fla File >?
how to import a .swf into a .fla file >?
what other program do i need ?
please email me at flyboyy@hotmail.com if you know any information about that TIA ...

>>IMPORT TXT FILE...HELP<<
ne1 know what the maximum character/word count flash allows to be imported dynamically from an external txt file??? is there even a limit?

thx.

I Have A Big .mov File To Import...
HI GUYS:

I have a 80MB .mov file that I whant to import or embeded on my .fla file . Its to large to do it or I have to edit the .mov file on the Quick time Pro for Exporting on a smallest file?
How can I do that?

Thanks

WMV File Cannot Import Them
Why can't I import WMV files into Flash MX 2004 Professional.
I can do it at home but I cannot do it at work. Could I be missing a file or update of some sort.. Please help..
Thanks

Import .fla File
hello

i have an .fla file which is my intro.
and i have an .fla file which is my main scene.
i need to have ONE final projector file in the end.

how can i import the 2nd file to the first (or the opposite) as a new scene and have everything working?
do i copy paste all the frames? what happens then with my movie clips of the imported file... do they come along?

any hints?

thanks

Import PNG File?
I want to import a png image into a movie clip at runtime, dynamically with code.

Is this even possible? I know you can use loadMovie() to load a .jpg in this way, but I need to load in several .png files that have alpha transparency.
Thanks in advance..

-nj

.txt File As Import?
Hi,

I'm currently using loadVars to load in a .txt file at run time, is there any way that can be done before run time? using import or something? I don't want to cut and paste it all into an array either!

thanks for any help
boombanguk

Import A SWF File ?
Hey there... I have created a cartoon character, in a seperate flash file on it's own. It has recurring movement, of walking. However it does not move left to right accross the screen.

On another flash file i want to import this swf file into a moveclip which i can tween left to right.

Can i import a seperate SWF file into a movieclip on another movie? How?

Thanks!

Really? Can't Import An AS File.
My first foray into Flash and AS3 and it's quite frustrating... but I like it

All I'm trying to do here is separate some code... throwing it into an ActionScript file. Code works perfectly fine when on the first frame, when I strip that code out and put it in an AS file, and import it...

import "mycode.as";

I get a syntax error on the line of import:


Quote:




1087: Syntax error: extra characters found after end of program.




This is straight out of a book and examples all over. My AS file is on root where my FLA is. When I replace the import line with my AS code again no issues.

What's the simple thing I'm missing? It doesn't have to be wrapped up in a package does it?

THX!

Cannot Import Mp3 File
Hi - I have flash mx professional 2004 on xp pro - when I try to import into
the library an mp3 file (which plays fine), I get this error:

"One or more files were not imported because there were problems reading
them."

The file is not read only. The audio bit rate is 320kps, 2 channels, 44khz.
As I say, I can play it fine from windows explorer.

Thanks for any help!

John

Copyright © 2005-08 www.BigResource.com, All rights reserved