# TextField.color

**URL:** <https://forum.kirupa.com/t/textfield-color/123386>\
**Category:** Uncategorized\
**Created:** [September 23, 2004, 4:33am UTC](https://forum.kirupa.com/t/textfield-color/123386 "2004-09-23T04:33:20Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ashishchandras](https://avatars.discourse-cdn.com/v4/letter/a/7993a0/32.png) [@ashishchandras](https://forum.kirupa.com/u/ashishchandras)\
**Post date:** [September 23, 2004, 4:33am UTC](https://forum.kirupa.com/t/textfield-color/123386/1 "2004-09-23T04:33:20Z")

</div>

Hi,

I have problem assigning color to a dynamic textfield using TextFormat Object. Does anybody knows??

## This example i got from Flash Help but this also doesnt work:

The following example creates a text field and sets the text color to red.

var my\_fmt:TextFormat = new TextFormat();  
my\_fmt.blockIndent = 20;

## this.createTextField(“my\_txt”, 1, 100, 100, 300, 100); my\_txt.multiline = true; my\_txt.wordWrap = true; my\_txt.textColor = “#C6032A” // this is what i worte but not working either my\_txt.border = true; my\_txt.text = “this is my first test field object text”; my\_txt.setTextFormat(my\_fmt);

* * *

aShIsH
