A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: Embedding Image with a source pathway which needs to change …?

  1. #1
    Senior Member
    Join Date
    Apr 2008
    Location
    Rotorua / New Zealand
    Posts
    117

    Embedding Image with a source pathway which needs to change …?

    Hi there,

    Well, I like to find out if it could be possible to use this normal type Embed code, and say have a pathway which is changing by selecting different Images in the Application with text from an Imput-Text field ??? without recompiling ??? Or better I say is it at all possible to Embed an Image once the App. is run ???

    Any help would be appreciated on this! regards aktell

    Code:
     
        [Embed(source="../assets/sample.jpg")]
        protected var jpgBytes:Class;

  2. #2
    Designer, Programmer, Musician angelhdz's Avatar
    Join Date
    Mar 2010
    Posts
    971
    I don't know about embbeding an image, but when the app is run, you can import any image inside a movieclip or on the stage directly using the Loader class.

    import flash.net.URLRequest;

    var myImageLoader:Loader = new Loader();

    myImageLoader.load(new URLRequest("assets/sample.jpg"));

    addChild(myImageLoader);
    Already mastering AS3. It was so fun. Now into Javascript and PHP and all its libraries

  3. #3
    Senior Member
    Join Date
    Apr 2008
    Location
    Rotorua / New Zealand
    Posts
    117
    Thanks I do know that as well it has to be Embedded as it is used in a written PDF file and I just wanted to avoid to Embed all requested Images!

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