dcsimg
A Flash Developer Resource Site

Results 1 to 9 of 9

Thread: Window Status Bar?

  1. #1
    Junior Member
    Join Date
    Apr 2002
    Posts
    5
    Hi,
    is it possible to write text in the window status bar from within a swf movie?

    thankx

  2. #2
    KoolMoves Moderator blanius's Avatar
    Join Date
    Jul 2001
    Location
    Atlanta GA
    Posts
    5,244

    yes you can

    Originally posted by glmaters
    Hi,
    is it possible to write text in the window status bar from within a swf movie?

    thankx
    If you know how from javascript just send an FSCOMMAND that is read by your javascript. Look in help and search here for info on using this.

  3. #3
    Junior Member
    Join Date
    Apr 2002
    Posts
    5
    OK,
    I defined Javascript functions in the HTML page calling the swf file.

    But I do not seem to be able to call these functions.
    Can somebody help with an example?

    Thanks,
    Gerard

  4. #4
    Junior Member
    Join Date
    Apr 2002
    Posts
    5
    Hi,
    Got the trick. Just needed a small VB Script to trigger the Javascript.
    It's working now.

    Thanks,
    Gerard

  5. #5
    KoolMoves Moderator blanius's Avatar
    Join Date
    Jul 2001
    Location
    Atlanta GA
    Posts
    5,244

    damn

    It doesn't work like it's supposed to......

    I've only managed to get it to work by using FLASH 5 and copying the script code where my flash movie is called fscommand_example:
    Code:
    <SCRIPT LANGUAGE=JavaScript>
    <!--
    var InternetExplorer = navigator.appName.indexOf("Microsoft") != -1;
    // Handle all the the FSCommand messages in a Flash movie
    function fscommand_example_DoFSCommand(command, args) {
      var fscommand_exampleObj = InternetExplorer ? fscommand_example : document.fscommand_example;
     window.status=args
    }
    // Hook for Internet Explorer 
    if (navigator.appName && navigator.appName.indexOf("Microsoft") != -1 && 
    	  navigator.userAgent.indexOf("Windows") != -1 && navigator.userAgent.indexOf("Windows 3.1") == -1) {
    	document.write('<SCRIPT LANGUAGE=VBScript\> \n');
    	document.write('on error resume next \n');
    	document.write('Sub fscommand_example_FSCommand(ByVal command, ByVal args)\n');
    	document.write('  call fscommand_example_DoFSCommand(command, args)\n');
    	document.write('end sub\n');
    	document.write('</SCRIPT\> \n');
    }
    //-->
    </SCRIPT>

  6. #6
    Senior Member kusco's Avatar
    Join Date
    Nov 2001
    Posts
    681

    better late than never...

    Hi Bret and Gerard,

    This link will take you to an example of how to use the FSCommand with 3DFA.

    http://www.syssoft.net.au/3dfa/load_vars_html.html

    All it does is load variables into edit boxes from the javascript in the web page. Click on the 'Load From HTML' text to see it work.

    If you view the source for the web page to the above link you can see the all the code used to achieve this.

    HTH

    Cheers,
    Ed

  7. #7
    KoolMoves Moderator blanius's Avatar
    Join Date
    Jul 2001
    Location
    Atlanta GA
    Posts
    5,244

    Re: better late than never...

    Originally posted by kusco
    Hi Bret and Gerard,

    This link will take you to an example of how to use the FSCommand with 3DFA.
    By the way Ed, you cannot use any of these javascript functions in Netscape 6+ as they did away with the liveconnect feature. I believe the FSCOMMAND function still is supposed to work.


    You can also send javascript commands via the LoadURL command like this:

    javascript:functiontocall

  8. #8
    Senior Member kusco's Avatar
    Join Date
    Nov 2001
    Posts
    681
    Hi Bret,

    Does that method of calling work for any browser (I only use IE)?

    Still, it's pretty neat that it can do that.

    Cheers,
    Ed


  9. #9
    KoolMoves Moderator blanius's Avatar
    Join Date
    Jul 2001
    Location
    Atlanta GA
    Posts
    5,244
    Originally posted by kusco
    Hi Bret,

    Does that method of calling work for any browser (I only use IE)?

    Still, it's pretty neat that it can do that.

    Cheers,
    Ed

    Yes I've used it to open PopUp Windows. Seems to work in all browsers

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