# createTextField() Input formating

**URL:** <https://forum.kirupa.com/t/createtextfield-input-formating/266671>\
**Category:** Uncategorized\
**Created:** [July 23, 2008, 9:36am UTC](https://forum.kirupa.com/t/createtextfield-input-formating/266671 "2008-07-23T09:36:20Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Patch](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/patch/32/1095_2.png) [@Patch](https://forum.kirupa.com/u/Patch)\
**Post date:** [July 23, 2008, 9:36am UTC](https://forum.kirupa.com/t/createtextfield-input-formating/266671/1 "2008-07-23T09:36:20Z")

</div>

hey,

I’m trying to format an input field that I have created with ActionScript with - createTextField.

I have managed to create one, but i’m currently unable to format it i.e. change font and colour etc.

here is the code i’m working with:

```auto

sMenu.createTextField("nTxt", getNextHighestDepth(), 10, 10, 150, 20);
	
	var myf:TextFormat = new TextFormat(); 
	myf.color = 0xFF0000;
	myf.font = "Arial";
	
	sMenu.nTxt.border = true;
	sMenu.nTxt.type = "input";
	sMenu.nTxt.tabEnabled = true
	
	sMenu.nTxt.setTextFormat(myf);

```

I’m just playing with it at the moment, I’ve never done this before.

Cheers!
