# Putting while... variable in MC path

**URL:** <https://forum.kirupa.com/t/putting-while-variable-in-mc-path/332631>\
**Category:** flash\
**Created:** [August 28, 2014, 7:25pm UTC](https://forum.kirupa.com/t/putting-while-variable-in-mc-path/332631 "2014-08-28T19:25:28Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![3dron](https://avatars.discourse-cdn.com/v4/letter/3/2acd7d/32.png) [@3dron](https://forum.kirupa.com/u/3dron)\
**Post date:** [August 28, 2014, 7:25pm UTC](https://forum.kirupa.com/t/putting-while-variable-in-mc-path/332631/1 "2014-08-28T19:25:28Z")

</div>

I can’t figure out why my variable in an MX path works in one instance but not in another.

Please help.

3dron

When running this SWF individually this works:  
while(i \< 35) {  
\_level0[“Sold10” + (i)].text = “Sold”;  
i++;  
}

When running from root SWF and this MC is loaded into \_level10.planContainer.Plan.FP

This works for me (showing the path):  
\_level10.planContainer.Plan.FP.Sold101.text = “Sold”;

But this doesn’t:  
while(i \< 35) {  
\_level10.planContainer.Plan.FP.[“Sold10” + (i)].text = “Sold”;  
i++;  
}
