Re: [Flashcoders] Swf not loading at run time

2007-06-11 Thread Cedric Muller

Hello John,

Could you please give some code ? (how you declare your hub, how you  
load your swf file)

And do you have an online example ?
hth,
Cedric


Hi guys,

I am going insane, please give me a hint,

I have a swf embedded in a html doc (the intro). this when  
completed loads another swf (the main interface). I have an empty  
mc into which I load another swf (showcase) which dynamically  
displays a variety of image presentation.


When testing the Movie from the authoring environment, everything  
works like a charm but when I publish and view the html in the  
browser the showcase.swf does not seem to be loading; I have the  
same issue  also when I open the swf file from the player


The html and all swf files reside in the same folder at the same  
level.  I have double checked and tried everything I know and I am  
getting quite desperate now as I don't know what else to do.


Is there any simple reason/issue with the implementation? What else  
can I try to resolve this?


thanks
JohnT
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


RE: [Flashcoders] Swf not loading at run time

2007-06-11 Thread vivek
Can u give part of the script which is loading swf files?

-Original Message-
From: John Trentini [mailto:[EMAIL PROTECTED] 
Sent: Monday, June 11, 2007 3:08 PM
To: Flashcoders@chattyfig.figleaf.com
Subject: [Flashcoders] Swf not loading at run time

Hi guys,

I am going insane, please give me a hint,

I have a swf embedded in a html doc (the intro). this when completed 
loads another swf (the main interface). I have an empty mc into which I 
load another swf (showcase) which dynamically displays a variety of 
image presentation.

When testing the Movie from the authoring environment, everything works 
like a charm but when I publish and view the html in the browser the 
showcase.swf does not seem to be loading; I have the same issue  also 
when I open the swf file from the player

The html and all swf files reside in the same folder at the same level.  
I have double checked and tried everything I know and I am getting quite 
desperate now as I don't know what else to do.

Is there any simple reason/issue with the implementation? What else can 
I try to resolve this?

thanks
JohnT
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Swf not loading at run time

2007-06-11 Thread John Trentini
Vivek, sorry I think I have sent my ealier reply to your personal email 
(If I don't remember to 'reply all', thunderbird just uses the personal 
address of the sender, sheesh!),


here is the code:

dropBtn.onPress = function() {
  //make the showContainer_mc visible
  showContainer_mc._visible = true;
  dropBtn_txt.text = myName;
  //trace(thisName);
  if (myName == sea bounty  thisName == brand development) {
  showContainer_mc.loadMovie(SeaBounty.swf); // this call 
works, sgtrtangely enough

  } else {
  showContainer_mc.loadMovie(showcase.swf); // this one is 
the one that does not work

  }
  loaded = true;
  removeDropMenu();
  };
The DropBtn are created dynamically and i make the fucntion call from 
the constructor.


Cheers
JohnT
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Swf not loading at run time

2007-06-11 Thread Cedric Muller

NP, did not see :P
So here is a copy of the reply I sent to your personal email for  
everyone to rejoice :)

**
try
loadMovie(SeaBounty.swf, showContainer_mc);
and
loadMovie(showcase.swf, showContainer_mc);

Seems subtle, and is **abstract**, but loadMovie is either a global  
function, or a method of the MovieClip object.
When calling myMovieClip.loadMovie(bob.swf), you simply override  
all the movieclip's parameters and properties. Consequently, after  
the first showContainer_mc.loadMovie(...),  
showContainer_mc.loadMovie's method gets deleted, overriden by the  
new SWF being loaded at its place.
So when you try to call the method the second time (else statement),  
it isn't there anymore.
By simply calling loadMovie(showcase.swf, showContainer_mc);  
(without the myMC.loadMovie notation) and passing the link reference  
(1st argument) and the container reference (2nd argument), you get  
the new content everytime you want (or need).


Hth,
Cedric

Cedric, sorry I think I have sent my ealier reply to your personal  
email address, my apologies

here is the code I use:

dropBtn.onPress = function() {
  //make the showContainer_mc visible
  showContainer_mc._visible = true;
  dropBtn_txt.text = myName;
  //trace(thisName);
  if (myName == sea bounty  thisName == brand development) {
  showContainer_mc.loadMovie(SeaBounty.swf); // this call  
works, sgtrtangely enough

  } else {
  showContainer_mc.loadMovie(showcase.swf); // this one  
is the one that does not work

  }
  loaded = true;
  removeDropMenu();
  };
The DropBtn are created dynamically and i make the fucntion call  
from the constructor.


Cheers
JohnT
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


RE: [Flashcoders] Swf not loading at run time

2007-06-11 Thread vivek
 

 

-Original Message-
From: John Trentini [mailto:[EMAIL PROTECTED] 
Sent: Monday, June 11, 2007 4:10 PM
To: flashcoders@chattyfig.figleaf.com
Subject: Re: [Flashcoders] Swf not loading at run time

 

Cedric, sorry I think I have sent my ealier reply to your personal email 

address, my apologies

here is the code I use:

 

dropBtn.onPress = function() {

   //make the showContainer_mc visible

   showContainer_mc._visible = true;

   dropBtn_txt.text = myName; // what is the use of this step? Below you
are using myName what is the value of myName?

   //trace(thisName);

   if (myName == sea bounty  thisName == brand development) {

   showContainer_mc.loadMovie(SeaBounty.swf); // this call 

works, sgtrtangely enough

   } else {

   showContainer_mc.loadMovie(showcase.swf); // this one is 

the one that does not work

   }

   loaded = true;

   removeDropMenu();

   };

The DropBtn are created dynamically and i make the fucntion call from 

the constructor.

 

Cheers

JohnT

___

Flashcoders@chattyfig.figleaf.com

To change your subscription options or search the archive:

http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

 

Brought to you by Fig Leaf Software

Premier Authorized Adobe Consulting and Training

http://www.figleaf.com

http://training.figleaf.com

 

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Swf not loading at run time

2007-06-11 Thread Cedric Muller

By the way,
you might want to loop up the MovieClipLoader class, which is  
somewhat very useful ;)

I personally recommend you this technique.

var mclListenerObj = new Object();
mclListenerObj.onLoadInit = function (target_mc:MovieClip) {
trace(loaded +target_mc);
}
var mcl = new MovieClipLoader();
mcl.addListener(mclListenerObj);
mcl.loadClip(showcase.swf, showContainer_mc);

Lookup MovieClipLoader in the Help files. You get a list of all  
available events (onLoadStart, onLoadProgress, onError, ..)

and more ;)

hth,
Cedric


NP, did not see :P
So here is a copy of the reply I sent to your personal email for  
everyone to rejoice :)

**
try
loadMovie(SeaBounty.swf, showContainer_mc);
and
loadMovie(showcase.swf, showContainer_mc);

Seems subtle, and is **abstract**, but loadMovie is either a global  
function, or a method of the MovieClip object.
When calling myMovieClip.loadMovie(bob.swf), you simply override  
all the movieclip's parameters and properties. Consequently, after  
the first showContainer_mc.loadMovie(...),  
showContainer_mc.loadMovie's method gets deleted, overriden by the  
new SWF being loaded at its place.
So when you try to call the method the second time (else  
statement), it isn't there anymore.
By simply calling loadMovie(showcase.swf, showContainer_mc);  
(without the myMC.loadMovie notation) and passing the link  
reference (1st argument) and the container reference (2nd  
argument), you get the new content everytime you want (or need).


Hth,
Cedric

Cedric, sorry I think I have sent my ealier reply to your personal  
email address, my apologies

here is the code I use:

dropBtn.onPress = function() {
  //make the showContainer_mc visible
  showContainer_mc._visible = true;
  dropBtn_txt.text = myName;
  //trace(thisName);
  if (myName == sea bounty  thisName == brand  
development) {
  showContainer_mc.loadMovie(SeaBounty.swf); // this  
call works, sgtrtangely enough

  } else {
  showContainer_mc.loadMovie(showcase.swf); // this one  
is the one that does not work

  }
  loaded = true;
  removeDropMenu();
  };
The DropBtn are created dynamically and i make the fucntion call  
from the constructor.


Cheers
JohnT
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Swf not loading at run time

2007-06-11 Thread John Trentini

Vivek,

The 'dropBtn_txt.text = myName' is only a place holder to hold the name 
of the subMenu button being clicked into an off stage text field. The 
'showcase.swf' uses this value together with the content of another off 
stage field (thisName) to build a path to external data it uses to build 
the relevant display


I have a number of menu items created dynamically which, when clicked 
create a dropdDown menu with a range of items depending on the external 
data. 'thisName' is the label of the menu item that, when clicked, 
creates the dropDown menu and myName is the label of the dropDown button.


This is as clear as I can make it.

Because I have to load and unload things while ate the same times having 
to sert and unset booleans, I have gone trhough teh code with as fine a 
toothcomb as my brain can master but here i am, tearing off the last of 
teh few hairs remaining on the top of my head.
I have bebugged the whole lot as I was building it up but strange thing, 
a trace inserted just after the dropBtn_txt.text = myName, does not 
output anything and my brian is so very dead at the moment (long day)


^_^

JohnT


vivek wrote:


-Original Message-
From: John Trentini [mailto:[EMAIL PROTECTED]
Sent: Monday, June 11, 2007 4:10 PM
To: flashcoders@chattyfig.figleaf.com
Subject: Re: [Flashcoders] Swf not loading at run time

Cedric, sorry I think I have sent my ealier reply to your personal email

address, my apologies

here is the code I use:

dropBtn.onPress = function() {

//make the showContainer_mc visible

showContainer_mc._visible = true;

dropBtn_txt.text = myName; *// what is the use of this step? Below you 
are using “myName” what is the value of myName?*


//trace(thisName);

if (myName == sea bounty  thisName == brand development) {

showContainer_mc.loadMovie(SeaBounty.swf); // this call

works, sgtrtangely enough

} else {

showContainer_mc.loadMovie(showcase.swf); // this one is

the one that does not work

}

loaded = true;

removeDropMenu();

};

The DropBtn are created dynamically and i make the fucntion call from

the constructor.

Cheers

JohnT

___

Flashcoders@chattyfig.figleaf.com

To change your subscription options or search the archive:

http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software

Premier Authorized Adobe Consulting and Training

http://www.figleaf.com

http://training.figleaf.com



___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Swf not loading at run time

2007-06-11 Thread John Trentini

Cedric, this is good but,
before i go into implementing yet more new code, let me ask something first:
What could explain the fact the project works well when testing the 
movie in the authoring environment but not at run time?
What are the issues that could prevent it from finding/displaying one 
swf file and not the other?


I will try your code because. at least it may trace the error for me but 
the original question is still 'lurking' ;)


Cheers
JohnT

Cedric Muller wrote:


By the way,
you might want to loop up the MovieClipLoader class, which is  
somewhat very useful ;)

I personally recommend you this technique.

var mclListenerObj = new Object();
mclListenerObj.onLoadInit = function (target_mc:MovieClip) {
trace(loaded +target_mc);
}
var mcl = new MovieClipLoader();
mcl.addListener(mclListenerObj);
mcl.loadClip(showcase.swf, showContainer_mc);

Lookup MovieClipLoader in the Help files. You get a list of all  
available events (onLoadStart, onLoadProgress, onError, ..)

and more ;)

hth,
Cedric


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Swf not loading at run time

2007-06-11 Thread Muzak

 When calling myMovieClip.loadMovie(bob.swf), you simply override
 all the movieclip's parameters and properties. Consequently, after  the first 
 showContainer_mc.loadMovie(...), 
 showContainer_mc.loadMovie's method gets deleted, overriden by the  new SWF 
 being loaded at its place.
 So when you try to call the method the second time (else statement),  it 
 isn't there anymore.

That's not correct. The initial movieclip (holder) doesn't go anywhere..
Anything inside the movieclip will go *poof*..

 By simply calling loadMovie(showcase.swf, showContainer_mc);  (without the 
 myMC.loadMovie notation) and passing the link 
 reference  (1st argument) and the container reference (2nd argument), you get 
  the new content everytime you want (or need).


The global loadMovie function is just very old syntax (Flash Player 3) and 
shouldn't be used anymore.
MovieClip.loadMovie was introduced in Flash 5 and has been the prefered way for 
loading external assets, until the MovieClipLoader 
class was introduced in Flash 7, which has events for monitoring the loading 
progress.

regards,
Muzak


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Swf not loading at run time

2007-06-11 Thread John Trentini

Thanks for the clarification Muzac,

would you know what could possibly make the project not work at run time 
while it works in test Movie?


cheers
JohnT

Muzak wrote:


When calling myMovieClip.loadMovie(bob.swf), you simply override
all the movieclip's parameters and properties. Consequently, after  the first showContainer_mc.loadMovie(...), 
showContainer_mc.loadMovie's method gets deleted, overriden by the  new SWF being loaded at its place.

So when you try to call the method the second time (else statement),  it isn't 
there anymore.
   



That's not correct. The initial movieclip (holder) doesn't go anywhere..
Anything inside the movieclip will go *poof*..

 

By simply calling loadMovie(showcase.swf, showContainer_mc);  (without the myMC.loadMovie notation) and passing the link 
reference  (1st argument) and the container reference (2nd argument), you get  the new content everytime you want (or need).


   



The global loadMovie function is just very old syntax (Flash Player 3) and 
shouldn't be used anymore.
MovieClip.loadMovie was introduced in Flash 5 and has been the prefered way for loading external assets, until the MovieClipLoader 
class was introduced in Flash 7, which has events for monitoring the loading progress.


regards,
Muzak


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

 



___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com