A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: Directory paths for external swfs.

  1. #1
    Junior Member
    Join Date
    Apr 2003
    Posts
    17

    Directory paths for external swfs.

    Is there any way to load an external swf, residing in a different directory to the projector, when running off a CD.

    I have read a lot of posts that tell you have to run the swfs from the same directory as the exe but it makes it really messy as I have many external images and swfs and want the projector to be in the root directory of a CD and the other files to be in another directory.

  2. #2
    Banned By GMF Wannabe Gambini's Avatar
    Join Date
    Oct 2000
    Posts
    976
    Ofcourse!
    Code:
    loadMovieNum("subFolder/myMovie.swf", 5);
    Hope this helps!
    Last edited by Gambini; 02-16-2004 at 01:57 PM.

  3. #3
    Lifetime Friend of Site Staff Northcode's Avatar
    Join Date
    Dec 2000
    Location
    Whitehorse YT
    Posts
    3,766
    In a string literal you should always escape "\" characters with another "\" character like this:

    loadMovieNum("subFolder\\myMovie.swf", 5);

    Alternatively you can use the "/" as a path separator like this..

    loadMovieNum("subFolder/myMovie.swf", 5);

    Check out section 4.5.2.2 "Escape sequences" from Colin Moock's book, ActionScript : The Definitive Guide. You can read the relevant section online at http://skaiste.elekta.lt/Books/O'Rei...on/ch04_05.htm

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center