# Is this wrong code?

**URL:** <https://forum.kirupa.com/t/is-this-wrong-code/222536>\
**Category:** Uncategorized\
**Created:** [April 14, 2007, 2:08pm UTC](https://forum.kirupa.com/t/is-this-wrong-code/222536 "2007-04-14T14:08:55Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![cenapibo](https://avatars.discourse-cdn.com/v4/letter/c/bbce88/32.png) [@cenapibo](https://forum.kirupa.com/u/cenapibo)\
**Post date:** [April 14, 2007, 2:08pm UTC](https://forum.kirupa.com/t/is-this-wrong-code/222536/1 "2007-04-14T14:08:55Z")

</div>

hi everyone  
l have been trying something but l failed, so l need your advice,  
that is my button code (no problem with it )

[COLOR=darkred]on (release) {  
if (\_root.link != 2) {  
\_root.menu[(“item” + \_root.link)].gotoAndPlay(“s2”);  
\_root.link = 2;  
\_root.pages.play();  
}  
}[/COLOR]  
[COLOR=#8b0000][/COLOR]  
[COLOR=black]and that is my timeline action [/COLOR][COLOR=black][COLOR=darkred]gotoAndPlay("(“p” + \_root.link)"); [COLOR=black]the problem is this code[/COLOR] [/COLOR][/COLOR]  
[COLOR=#8b0000][/COLOR]  
[COLOR=#8b0000][/COLOR]  
[COLOR=#8b0000][COLOR=black] **pages** is a sembol and in it there is a long movie clip (pages), the above code is considering the right page, when the button is clicked this code [/COLOR][/COLOR][COLOR=#8b0000]gotoAndPlay("(“p” + \_root.link)");[/COLOR][COLOR=black]is going to the label and playing this label but flash says this code has error. [/COLOR]

l dont know what to do

thanks  
[COLOR=black][COLOR=#8b0000][/COLOR][/COLOR]  
[COLOR=black][COLOR=#8b0000][/COLOR]  
[/COLOR]
