• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Javascript

New Here ,
Feb 24, 2021 Feb 24, 2021

Copy link to clipboard

Copied

Hi there,

 

Hope y'all are well.

Someone can give a hand.

I'm converting a code form AC to JS, most of the job is already done, the problem that I am facing is how can I close the flash.

I'm using this function that I checked in Convert your ActionScript code to HTML5 (adobe.com)

window.open("javascript:flashFinished()", "_self").

Am I right, or is there another way to do it?

This is my code

this.stop();

var frequency = 3;
var exitStr = termi

stage.enableMouseOver(frequency);

this.btFinish.addEventListener("mouseover", function fl_MouseEventFinish()
{
mcFinish.gotoAndStop();
});

this.btFinish.addEventListener("mouseover", function fl_MouseEventFinish()
{
mcFinish.gotoAndStop();
});

this.btFinish.addEventListener("click", fl_MouseEventFinish.bind(this));

function fl_MouseEventFinish()
{
window.open("flashFinished()", "_self");

//this.gotoAndStop("S1");
}

Hope you guys can help me.
Hasta luego amigos




TOPICS
ActionScript , Code , How to , Import and export

Views

126

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Feb 24, 2021 Feb 24, 2021

Copy link to clipboard

Copied

That code is correct... IF you're trying to navigate to a website named "javascript:flashFinished()".

 

Are you?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 24, 2021 Feb 24, 2021

Copy link to clipboard

Copied

thank you for your help,

I just wanted to close the flash (at the meantime I have realsed wrote wrong), BTW I found a way to do it, using the line below
window.open('','_self').close()

 

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Feb 24, 2021 Feb 24, 2021

Copy link to clipboard

Copied

LATEST

Umm... why would you not just use window.close()?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines