With(mc){...} Problem


_root.createEmptyMovieClip("mc",1)

with(mc){
myVar = "Hello" //I want this as mc.myVar but its _root.myVar
_x = 10
}

trace(mc.myVar) //undefined
trace(mc._x) //10

How can I set variables for ‘mc’ using with(){…} and why does it work for properties but not variables?
Do I have to use mc.myVar = … every time?
Thanks in advance!