# Format object not being applied to textfield

**URL:** <https://forum.kirupa.com/t/format-object-not-being-applied-to-textfield/147674>\
**Category:** Uncategorized\
**Created:** [May 12, 2005, 6:25pm UTC](https://forum.kirupa.com/t/format-object-not-being-applied-to-textfield/147674 "2005-05-12T18:25:35Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![silentweed](https://avatars.discourse-cdn.com/v4/letter/s/2acd7d/32.png) [@silentweed](https://forum.kirupa.com/u/silentweed)\
**Post date:** [May 12, 2005, 6:25pm UTC](https://forum.kirupa.com/t/format-object-not-being-applied-to-textfield/147674/1 "2005-05-12T18:25:35Z")

</div>

Hi my textformat object for some reason is not being applied to the dynamically created text fields…(note in my library i have the font with linkage name VerdanaShared and this is imported at runtime from the shared library.

Now i have the following code which basically populates textfields with music track info:

```auto

function populateMenuList():Void{
	var menuMovie:MovieClip;
	var nY:Number=322;
	var nX:Number=170;
	var text_fmt:TextFormat = new TextFormat();
	text_fmt.font = "VerdanaShared";
	text_fmt.size =12;
	text_fmt.color = 0x999999;
	
for(var i:Number=1; i<=totalTracks;i++){
menuMovie=_root.createEmptyMovieClip("menuList"+i,_root.getNextHighestDepth());
	menuMovie.createTextField("track"+i,menuMovie.getNextHighestDepth(),0,0,200,200);
	
	menuMovie["track"+i].setTextFormat(text_fmt);
	menuMovie["track"+i].text= myLV_lv["track"+i];
}

```

this does not seem to apply the format object…does anyone know why? Ive also tried adding the line menuMovie[“track”+i].embedFonts=true before menuMovie[“track”+i].setTextFormat(text\_fmt); but then the text completey dissappears when i test the movie!!!

Any help appreciated…thanks!!!
