Changing font of a text window

How would I dynamically change the font / size / bold of a text box? I made a script that would work, but the font/size/bolding would have to be entered first… check it out

http://members.lycos.co.uk/dudeman26/pop up test.fla

[AS]_root.createTextField(“myTextField”, 100, 150, 20, 150, 16);
with (myTextField) {
autosize = true;
border = true;
size = 12;
text = “This is dummy text”;
}
myformat = new TextFormat();
with (myformat) {
bold = true;
size = 14;
font = “Arial”;
}
_root.createEmptyMovieClip(“btn”, 101);
with (btn) {
lineStyle(1.5, 0x666666, 100);
beginFill(0x999999, 100);
moveTo(100, 20);
lineTo(130, 20);
lineTo(130, 36);
lineTo(100, 36);
endFill();
}
btn.onPress = function() {
myTextField.setTextFormat(myformat);
};

Theres an error w/ ‘with’ : [AS]Error: A ‘with’ action failed because the specified object did not exist.[/AS]

In my example I want it to be changed real-time by the user, so basicly they insert their font options in a little textbox, download it and try it out… thanks

*Originally posted by dudeman *
**In my example I want it to be changed real-time by the user, so basicly they insert their font options in a little textbox, download it and try it out… thanks **

What options you want?

It says inside the check button… edit inside the window and you will see.

So basicly its font/size/bolding…

here

Ahaha thanks… smart one, I gotta hand it to you :stuck_out_tongue:

Let me just incorporate the change to take place when the check it clicked

welcome :thumb:
i was having trouble with the radiobutton