# Target Path using variables?

**URL:** https://forum.kirupa.com/t/target-path-using-variables/216710
**Category:** flash
**Created:** [February 19, 2007, 9:43pm UTC](https://forum.kirupa.com/t/target-path-using-variables/216710 "2007-02-19T21:43:45Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![ZumoWrestler](https://avatars.discourse-cdn.com/v4/letter/z/f05b48/32.png) [@ZumoWrestler](https://forum.kirupa.com/u/ZumoWrestler)
#### Post date: [February 19, 2007, 9:43pm UTC](https://forum.kirupa.com/t/target-path-using-variables/216710/1 "2007-02-19T21:43:45Z")

</div>

Hey everyone,

I’ve run into a problem where I want to use a variable as part of a target path…example…

```auto
var myVar:String = String("myMC");
 
//say I have a MC with this path...this.myMC
this.myVar._y = 3;

```

is there a way to do something like this? Everything I try doesn’t work, yet I can use this concept in a different way.

```auto

//this works fine
var newColor:Color = new Color("States." + myArray*);

```

I have tried the tellTarget(object) also the with(object) but I can’t seem to get anything to work. Any ideas?
