Variable communication

I am playing around trying to teach myself actionscript and I’m getting frustrated with a simple dynamic textbox. I have a main movie with just one frame and in the frame actionscript I have :

newitemwidth;
totallength = 10 + newitemwidth;

I have a button on this main movie that on release, among other things, has:

newitemwidth = 115;

I have a dynamic textbox on the movie as well with the variable set to:

totallength

When I test the movie, the textbox shows 10, but when I click the button it doesn’t change to 125 with the added newitemwidth. Am I missing some rule about global variables here? Thanks for your help.

BriCar77
[email protected]