Can't get script working to read dynamic text

Hi all

ok, i have been working with this text to load in dynamic text fields. what I have is a movieclip called ‘textInfo’ inside this two dynamic text fields called ‘headerTex1’ and ‘headerText2’ where I want the text to load into from the XML file.

the text should appear next to image that rotate on menu which has 25 images on the menu.

What I am getting confused with is do I need to repeat the script 25 times with 25 differently labeled movieclips and text fileds, aaarrrrggghhh!

this is the script;

var textInfo:TextInfo = new TextInfo();

textInfo.headerText1.text = images*.@headerText1;
textInfo.bodyText1.text = images*.@bodyText1;
addChild(textInfo1);

             textInfo.x=120;
              textInfo.y=300;

my other concern is that using the x & y position fixes the text but I would like it to rotate next to the images, am I making any sense?

can any one help