Indigo Rose Software

Professional Software Development Tools

 
Results 1 to 11 of 11
  1. #1
    Join Date
    Mar 2007
    Posts
    8

    Html links in flash movie ?

    I want to add html links in flash movie but when user clicks on links they are taken to http://file.html which is incorrect. What I want is to be opened from cd rom like file:///E:/file.html. How can I do that? A flash example would be great. Thank you

  2. #2
    Join Date
    Mar 2007
    Posts
    8
    I have found the following commands from an older version but it gives error:

    %FSCommand% = FlashObject(Flash1).GetProperty("Last FSCommand")
    IF (%FSCommand%="alfaromeo")
    File.Open (open, "%ScrDir%\folder\file.html")
    END IF

    The error is Line1=": unexpected symbol near '%'

    Can someone please correct the commands and also the commands in flash would be gorgeous.
    Thank you

  3. #3
    Join Date
    Aug 2003
    Posts
    2,427
    The way to use fsCommand is different in the current version of AMS. When you have inserted a flash object, in the object's properties you will see an "On FSCommand" event in the script tab. Put something like this in to that event -

    Code:
    if e_FSCommand=="alfaromeo" then
    File.Open("AutoPlay\\Docs\\file.html", "", SW_SHOWNORMAL);
    end
    Instead of opening the html you could have a web object on your page and use the Web.LoadURL action to load the page inside AMS.

    p.s. Have a look in the help file under "fsCommand".
    Last edited by longedge; 10-17-2007 at 04:16 PM.

  4. #4
    Join Date
    Mar 2007
    Posts
    8
    Quote Originally Posted by longedge View Post
    The way to use fsCommand is different in the current version of AMS. When you have inserted a flash object, in the object's properties you will see an "On FSCommand" event in the script tab. Put something like this in to that event -

    Code:
    if e_FSCommand=="alfaromeo" then
    File.Open("AutoPlay\\Docs\\file.html", "", SW_SHOWNORMAL);
    end
    Instead of opening the html you could have a web object on your page and use the Web.LoadURL action to load the page inside AMS.

    p.s. Have a look in the help file under "fsCommand".
    Thank you for respond. Ok I put that in AMS, what should I put the button in flash? And I want to open the page in new window, because user should be able to close it and return to AMS because there will be main swf and user will chose what button to click. Where is Web.LoadURL ? In Flash or AMS?
    Thank you again.

  5. #5
    Join Date
    Aug 2003
    Posts
    2,427
    In flash you have a button, movie clip etc which 'on release' has an action fscommand("alfaromeo");.

    In AMS on the page you have a flash object which contains the swf and that "listens" for fsCommand coming from the flash object and when one occurs it tests to see if it is the fsCommand specified and reacts in the way specified in your code.

    In AMS you can have a web object on the page. You can use the action Web.LoadURL to load a page into the web object.

    Hope that is clearer
    Last edited by longedge; 10-17-2007 at 04:45 PM.

  6. #6
    Join Date
    Aug 2003
    Posts
    2,427
    An example for you which I hope will make things clearer

  7. #7
    Join Date
    Mar 2007
    Posts
    8
    Quote Originally Posted by longedge View Post
    An example for you which I hope will make things clearer
    Thank you so much but I can not open html files on AMS, I have tı open them on a new window of explorer as whole of my work is flash. In your examples, there is a space to open html file. But I have to open them from cd rom. So I yhink only fs command in flash and fs command listener in AMS will be enough. Web.LoadURL is not needed. I need to open from cd rom and drive letter is different on computers sı fs command must do this job.
    Thank you

  8. #8
    Join Date
    Aug 2003
    Posts
    2,427
    Quote Originally Posted by ozgurerdogan View Post
    Thank you so much but I can not open html files on AMS, I have tı open them on a new window of explorer as whole of my work is flash. In your examples, there is a space to open html file. But I have to open them from cd rom. So I yhink only fs command in flash and fs command listener in AMS will be enough. Web.LoadURL is not needed. I need to open from cd rom and drive letter is different on computers sı fs command must do this job.
    Thank you
    Since this is the forum for AMS6, I assumed we were talking about working in an AMS project

    Still talking about AMS, if in my example you change the line in the flash object on fsCommand event from -

    Web.LoadURL("Web1", "http://www.indigorose.com");
    TO
    File.OpenURL("AutoPlay\\Docs\\file.html", SW_SHOWNORMAL);

    - then it will open in the users default web browser. It doesn't matter if the file is on a CD or Hard Drive as long as it's in the AMS Docs folder.

  9. #9
    Join Date
    Mar 2007
    Posts
    8
    Quote Originally Posted by longedge View Post
    Since this is the forum for AMS6, I assumed we were talking about working in an AMS project

    Still talking about AMS, if in my example you change the line in the flash object on fsCommand event from -

    Web.LoadURL("Web1", "http://www.indigorose.com");
    TO
    File.OpenURL("AutoPlay\\Docs\\file.html", SW_SHOWNORMAL);

    - then it will open in the users default web browser. It doesn't matter if the file is on a CD or Hard Drive as long as it's in the AMS Docs folder.

    This is exatly what I was asking for. Thank you so much you saved my life
    I will try and post result in few hours thank you again. This is very kind of you.

  10. #10
    Join Date
    Mar 2007
    Posts
    8
    Thank you very much. Thats why I love forums

  11. #11
    Join Date
    Aug 2003
    Posts
    2,427
    Quote Originally Posted by ozgurerdogan View Post
    Thank you very much. Thats why I love forums
    You're welcome, glad it helped.

Similar Threads

  1. How to insert bullet in a paragraph object
    By jrak in forum AutoPlay Media Studio 6.0
    Replies: 13
    Last Post: 12-29-2005, 10:53 AM
  2. Flash movie - low playback quality
    By yosik in forum AutoPlay Media Studio 5.0
    Replies: 4
    Last Post: 02-15-2005, 03:43 PM
  3. Playing a Macromedia Flash Movie
    By Desmond in forum AutoPlay Media Studio 5.0 Examples
    Replies: 0
    Last Post: 09-26-2003, 12:59 PM
  4. Using Flash movie
    By everglade in forum AutoPlay Media Studio 4.0
    Replies: 1
    Last Post: 02-25-2003, 11:04 AM
  5. HOWTO: Install the Flash Player from a CD-ROM
    By Support in forum AutoPlay Media Studio 4.0 Examples
    Replies: 0
    Last Post: 10-29-2002, 04:05 PM

Posting Permissions

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