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

buttons

Explorer ,
Jul 25, 2023 Jul 25, 2023

Copy link to clipboard

Copied

Hi Guys

I have a lot f button in my project. I am making an interactiv book 28 pages in all. each page has on average 3 buttons a back btn, next btn and home btn. Some pages also have buttons for frame by frame animation all working well. My problem is on the 7th frame/page of my book I put in the usual 3 btns back,next and home, they roll over and change colour ok but they dont move to their asigned pages. 

Help! Alan Y

Views

346

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 3 Correct answers

Community Expert , Jul 25, 2023 Jul 25, 2023

check your button's instance name.

 

if that fails to show the problem, carefully copy the instance name from your code, remove your button from the stage, re-add your button to the stage and paste the button name (making sure there are no spaces) and retest.

Votes

Translate

Translate
Community Expert , Jul 27, 2023 Jul 27, 2023

i don't know about animate assigning a name (that you could see in the properties panel), but glad you checked and fixed the problem.

Votes

Translate

Translate
LEGEND , Jul 27, 2023 Jul 27, 2023

You absolutely should NOT be implementing your basic navigation as the same set of three buttons duplicated 28 times. That will be a nightmare to maintain and modify. Want to slightly adjust the position of a button? Now you have to make the same change 28 times.

 

What you should be doing is creating the three nav buttons ONCE, then coding them to move back and forth from the current page.

Votes

Translate

Translate
Community Expert ,
Jul 25, 2023 Jul 25, 2023

Copy link to clipboard

Copied

Hi.

 

Can we see the related code?

 

Regards,

JC

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
Explorer ,
Jul 25, 2023 Jul 25, 2023

Copy link to clipboard

Copied

Screenshot 2023-07-25 123303.png

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 Expert ,
Jul 25, 2023 Jul 25, 2023

Copy link to clipboard

Copied

check your button's instance name.

 

if that fails to show the problem, carefully copy the instance name from your code, remove your button from the stage, re-add your button to the stage and paste the button name (making sure there are no spaces) and retest.

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
Explorer ,
Jul 27, 2023 Jul 27, 2023

Copy link to clipboard

Copied

Hi 

Removed the button and gave it an instance name and all working now. I think the problem was i let the computer add an instance name and it just gave numbers whitch caused a lot of confussion because i could not remember what numbers went with the buttons but giving them all an instance name from now on. Lesson learnt!

ps. Also confussion with program start frame 1 and actions starting at 0 and just add to that if button going forward put one number less but if button going back to frames you need to go two numbers less.  Hope that make sense!.

Anyway all working well now fingers x.

Thanks again

Alan Y

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 Expert ,
Jul 27, 2023 Jul 27, 2023

Copy link to clipboard

Copied

i don't know about animate assigning a name (that you could see in the properties panel), but glad you checked and fixed the problem.

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 Expert ,
Jul 25, 2023 Jul 25, 2023

Copy link to clipboard

Copied

Do you have an instance called button_25 at that frame and are you binding the event handler function so that the this keyword refers to the current parent?

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 ,
Jul 27, 2023 Jul 27, 2023

Copy link to clipboard

Copied

LATEST

You absolutely should NOT be implementing your basic navigation as the same set of three buttons duplicated 28 times. That will be a nightmare to maintain and modify. Want to slightly adjust the position of a button? Now you have to make the same change 28 times.

 

What you should be doing is creating the three nav buttons ONCE, then coding them to move back and forth from the current page.

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