Passing variable into onRelease

I’m in need of a little help. I have a simple navigation, and each item is declared in the array below. The corrresponding movie clips also have the same instance name, and when each nav item is clicked, the movie should go to and play a frame that has a label containing the same name.

// names changed for client privacy
var navItems = [“foo”, “bar”, “hot”, “chocolate”, “w00t”];

for (i=0; i < navItems.length; i++) {
caseStudySubNav[navItems*].onRelease = function(){
gotoAndPlay(navItems*); // does nothing
trace(navItems*); // traces as undefined
}
trace(navItems*); // traces the array values properly
}

Everytime I click a menu item the trace returns as undefined. How do I get the value of navItems as it passes through the array attached/pushed to the onRelease function?

Thanks