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

multiple buttons not working in Adobe Animate HTML5 Canvas doc

Community Beginner ,
Jan 17, 2019 Jan 17, 2019

Copy link to clipboard

Copied

I'm having trouble with multiple buttons (all with unique instance names) working. Some do but when I have an arrow cycling through some content, the first one works, then the subsequent ones don't. I'm using this code for each button and changing the instance name and function name each time. Other buttons work in layout but where they are replaced with another in the same spot, it doesn't work. Any idea how to fix?

this.Next2_btn.addEventListener("click", fl_ClickToGoToAndPlayFromFrame_44.bind(this));

function fl_ClickToGoToAndPlayFromFrame_44()

{

this.gotoAndStop(1);

}

Views

510

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

correct answers 1 Correct answer

LEGEND , Jan 17, 2019 Jan 17, 2019

If you're just swapping out one button for an identical button, then... why? Why not remove and replace the event listeners instead?

Votes

Translate

Translate
LEGEND ,
Jan 17, 2019 Jan 17, 2019

Copy link to clipboard

Copied

Open your browser dev console and check for errors.

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
Community Beginner ,
Jan 17, 2019 Jan 17, 2019

Copy link to clipboard

Copied

doesn't seem to be any, is there any reason different buttons with different instance names shouldn't click to frame numbers? Sooo frustrating. Other btns work ok, it's the ones in the same spot that replace eachother (arrowing through page content, for instance) that do it...

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 ,
Jan 17, 2019 Jan 17, 2019

Copy link to clipboard

Copied

LATEST

If you're just swapping out one button for an identical button, then... why? Why not remove and replace the event listeners instead?

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