• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 256
  • Last Modified:

TGoToFrame not working in Flash 3

I have a function in JavaScript that helps me jump to specific Scenes and frames within my movie. This code was working fine when I tested it on the Flash 4 control, but when I tried it with the Flash 3 control it no longer works. This only has to be implemented in IE5, but it has to work with the Flash 3 control for at least the next three months. Any ideas why this would work with F4 but not F3.

var movie
function go(num)
{
if (qIndex<10){
      movie="Q0"+qIndex+"/"
}
else{
      movie="Q"+qIndex+"/"
}
      if(movie_ready == "false")
            {
                  while(movie_ready == "false")
                  {
                        if(movieobject(moviename).PercentLoaded() == 100)
                        {
                              movieobject(moviename).TGotoFrame("MC Master/",num);
                              movieobject(moviename).TPlay("MC Master/");
                              if (num==95){
                                    movieobject(moviename).TGotoFrame(movie,0);
                              }
                              movie_ready = "true";
                        }
                  }
            }
            
      else
      {
            movieobject(moviename).TGotoFrame("MC Master/",num);
            movieobject(moviename).TPlay("MC Master/");
            if (num==95){
                  movieobject(moviename).TGotoFrame(movie,0);
            }
      }
}

This function is used to control the display of certain remediation movies that are called based upon specific user responses in a quiz.

Thanks,
0
ematlack
Asked:
ematlack
1 Solution
 
ematlackAuthor Commented:
By the way, it was published in Flash 3.
0
 
ematlackAuthor Commented:
By the way, it was published in Flash 3.
0
 
SuperMarioCommented:
Review the JavaScript commands for a FlashAPI object in the Flash3 documentation. I know a lot of stuff like that changed over the versions...

-D
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
ematlackAuthor Commented:
According to tech note #13246 on Macromedia's supprt site, both of these methods are supported in Flash 3

TGotoFrame (String target, int frameNum)
 
TPlay (String target)

Is there another way to do this that you know is supported by Flash 3 that doesn't use TGotoFrame to access a frame within a speciic scene?
 
0
 
ematlackAuthor Commented:
Adjusted points from 50 to 200
0
 
ssdesignCommented:
How are you calling this script from flash, are you using FSCommand?

If so then the script will not work because flash3 does not support FSCommand

Hope this should make things clear for you.
0
 
SuperMarioCommented:
Wrong!

Flash 3 supports FS Command in full. I know this because I've used it a *bunch* in the past. Flash 4 is just more stable.

-D
0
 
ematlackAuthor Commented:
No,

Besides SuperMario's accurate response, the problem is not in the communication between Flash and the page, but between the page and Flash.
0
 
ematlackAuthor Commented:
My current thiking is that there must be a syntax difference in the way Flash 3 and Flash 4 call instances from outside Flash. However, it is very difficult to difinitively prove this assumption. There seems precious little information published on advanced techniques for interacting with Flash objects in Javascript.
0
 
SuperMarioCommented:
Can you make javaScript interact with your Flash movie *at all* ? Do any commands work with your Flash 3 control?

-dan
0
 
ematlackAuthor Commented:
So far only PercentLoaded() is returning results.
0
 
68kCommented:
hello -

funny you should ask this question.

issue:
TGotoFrame and TPlay methods aren't working with the Flash 3 player.

reason:
bug.

you can try an experiment - view this page with the flash 3 player vs the flash 4 player - netscape or ie (pc) or netscape/mac - and you will see it work only with the f4 player.

this method is *supposed* to work with the flash 3 player, according to this technote:

http://www.macromedia.com/support/flash/ts/documents/f3_script_methods.htm

but they do not, at least as is.

other methods (such as PercentLoaded) and such do work, but the ones that use a target (movie clip) do not.

why should you believe me? it's my day job. ;>)

sorry, i can't believe we didn't know this didn't work before.

i've been told that it *may* be possible through the fscommand in flash. however, simple tests confirm that these above clearly don't work in the flash 3 player.

my test of this:
http://63.194.219.30/jstest.html

pretty simple demonstration.

unfortunately, this can't be fixed. the only solution is to view these pages with the flash 4 player. i realize that this will preclude designing for flash 3 users, but i don't know of any way around this.

if i can be of any more help, let me know by replying here.

68k

aka
matt wobensmith
macromedia tech support
"the flash team lead"

0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now