Hey Bob,

as per your suggestion, I have done the code below, it seems has problem on
this. Would you please help me to take a look? Have a nice day :)

==================


var thumbHorizontalGap = 110;
//var url:String <http://mail.google.com/mail/String> = "
http://img0.gmodules.com/ig/images//weather_welcome_image.jpg";;

var arrURLs:Array =
["
http://l.yimg.com/us.yimg.com/i/us/ga/gameart2/perilendhouse/perilendhouse-100.gif
",
"
http://l.yimg.com/us.yimg.com/i/us/ga/gameart2/sallyssalon/sallyssalon-100.gif
",
"
http://l.yimg.com/us.yimg.com/i/us/ga/gameart2/riseofatlantis/riseofatlantis-100.gif
"]

for (var i:Number = 0; i<3; i++) {
 var url:String <http://mail.google.com/mail/String> = arrURLs[i];

 _root.createEmptyMovieClip("vThumb"+i,i+1000);
 vidThumb = eval("vThumb"+i);

 vidThumb._y = i*thumbHorizontalGap;
 vidThumb.loadMovie(url);

 vidThumb.onRelease = function() {
  openURL(url);
 };
 //trace(vidThumb);
}

function openURL(url) {
 getURL(url);
}

=================




On 1/13/08, Bob Leisle <[EMAIL PROTECTED]> wrote:
>
> You could put your URLs in an array and increment through it with each
> loop iteration, like this:
>
> ====================
>
> var thumbHorizontalGap = 75;
>
> var arrURLs:Array =
> ["http://img0.gmodules.com/ig/images//weather_welcome_image.jpg"; ,
>
> "http://img0.gmodules.com/ig/images//some_image.jpg"; ,
>
> "http://img0.gmodules.com/ig/images//someother_image.jpg"; ,
>
> "http://img0.gmodules.com/ig/images//yetanother_image.jpg"; ,
>
> "http://img0.gmodules.com/ig/images//onemore_image.jpg";
> ];
>
> for (var i:Number = 0; i< 5; i++)
> {
>    var url:String = arrURLs[i];
>    _root.createEmptyMovieClip("vThumb"+i, i+1000);
>
> vidThumb = eval("vThumb"+i);
>
>     vidThumb._y = i* thumbHorizontalGap;
>     vidThumb.loadMovie(url)
>
> vidThumb.onRelease = function(){
>   openURL(url)
> }
> }
>
>
>
> macromedia flash wrote:
> > AWESOME! thanks all :)
> >
> > One more question here... how can I assign URL link to each movieClip? I
> > would like to add URL for each of movieClip which created by looping,
> the
> > code like this....
> >
> > Thank you
> >
> > ====================
> >
> > var thumbHorizontalGap = 75;
> > var url: String = "
> > http://img0.gmodules.com/ig/images//weather_welcome_image.jpg";
> >
> > for (var i:Number = 0; i< 5; i++)
> > {
> >     _root.createEmptyMovieClip("vThumb"+i, i+1000);
> >
> >   vidThumb = eval("vThumb"+i);
> >
> >      vidThumb._y = i* thumbHorizontalGap;
> >      vidThumb.loadMovie(url)
> >
> >   vidThumb.onRelease = function(){
> >    openURL(url)
> >   }
> > }
> >
> > function openURL(url){
> >  getURL(url);
> > }
> > =====================
> >
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> Bob Leisle
> Headsprout Software & Engineering
> http://www.headsprout.com
> Where kids learn to read!
>
> _______________________________________________
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
>
_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to