# Target the \_root timeline with ' if ' statement

**URL:** https://forum.kirupa.com/t/target-the--root-timeline-with-if-statement/244657
**Category:** flash
**Created:** [November 20, 2007, 5:10pm UTC](https://forum.kirupa.com/t/target-the--root-timeline-with-if-statement/244657 "2007-11-20T17:10:10Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![Novate](https://avatars.discourse-cdn.com/v4/letter/n/3bc359/32.png) [@Novate](https://forum.kirupa.com/u/Novate)
#### Post date: [November 20, 2007, 5:10pm UTC](https://forum.kirupa.com/t/target-the--root-timeline-with-if-statement/244657/1 "2007-11-20T17:10:10Z")

</div>

Hi,

I am trying to target the stage of the sub loaded movie from the main timeline but with '\*\* if\*\* ’ statement:

**For example:**

1. I am inside swf file called market.swf and the length of the \_root timeline is only 10 frames

2. I am on the frame 1 of the \_root stage inside market.swf

3. I have a movie clip holder,

4. on this holder i load a another swf file called sales.swf

5. I am trying to control the \_root timeline of the sales.swf from market.swf but depending on the current frame position of the \_root stage (market.swf)

for example: if the current frame of my \_root (market.swf) is frame 8 then the \_root of sales.swf should stop on frame 4

this is really easy task to do, i mean i could easily achieve this by giving an instance name to the holder mc and target that mc with gotoAndStop

but what i really need to do is exactly this but with **if** statement

please anyone good with actionscript?

Thanks
