Hey All,
I’ve got a little scroller that pulls some database and uses it to display a series of images and links in a ScrollPane.
The images work just fine, but whenever I attach a TextField, it won’t display. The new scroll height is registered because the scroll bars are the appropriate size, but no text is rendered.
If I use the exact same code to attach it to _root it works just fine.
Here’s the bulk of the code:
The clips are being positioned correctly, and in debug mode it appears that all of the textfields are attached.
function PositionClips()
{
var TitleFormat:TextFormat = new TextFormat();
TitleFormat.align = "center";
TitleFormat.bold = true;
TitleFormat.font = "Arial";
TitleFormat.color = 0x660000;
TitleFormat.size = 16;
TitleFormat.underline = true;
for(i = 0;i<_root.ImageClips.length;i++)
{
var PortClip:MovieClip = _root.Scroller.spContentHolder["Port" + (i+1)];
with(PortClip)
{
_y = _root.CurrentY;
_root.CurrentY += _height + _root.Padding;
_x = Math.floor((_root.MaxWidth - _width)/2);
}
TextWidth = 0;
VerticalPos = PortClip._height + PortClip._y + 5;
_root.createTextField("Port" + (i+1) + "Title",i + 5,TextWidth,VerticalPos, 0,0);
var TitleText:TextField = _root["Port" + (i+1) + "Title"];
TitleText.text = _root.Titles*;
TitleText._url = _root.Links*;
TitleText.autoSize = true;
TitleText.setTextFormat(TitleFormat);
}
_root.Scroller.invalidate();
}