Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 61721
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 10, 20262026-05-10T18:21:48+00:00 2026-05-10T18:21:48+00:00

I create a TextArea in actionscript: var textArea:TextArea = new TextArea(); I want it

  • 0

I create a TextArea in actionscript:

var textArea:TextArea = new TextArea(); 

I want it to have a black background. I’ve tried

textArea.setStyle('backgroundColor', 0x000000); 

and I’ve tried

textArea.opaqueBackground = 0x000000; 

but the TextArea stays white. What should I do?

  • 1 1 Answer
  • 1 View
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-10T18:21:49+00:00Added an answer on May 10, 2026 at 6:21 pm

    TextArea is a UI component built from TextField and other Flash built-in classes and UIComponents. As with most of the Adobe UI components, nothing is as it seems when setting properties. To set the color of the area behind the text in the TextArea, you need to actually set the opaque background of its internal TextField using the textField property:

    var textArea:TextArea = new TextArea() textArea.textField.opaqueBackground = 0x000000; 

    Of course now that the background is black, the text can’t also be black, so we change its color using a new TextFormat:

    var myFormat:TextFormat = new TextFormat(); myFormat.color = 0xffffff; textArea.setStyle('textFormat',myFormat); 

    then just set the text and add to stage:

    textArea.text = 'hello'; addChild(textArea);  

    Also, if you want a little more control, there’s a nice extension class here that fixes a lot of the problems with TextArea:

    http://blog.bodurov.com/Post.aspx?postID=14

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I create a new Button object but did not specify the command option upon
Maybe I'm doing something wrong but I have a textarea where I've specified textAlign
I'm trying to create a multiline textarea in a php page, and I want
I'm using Javascript to create a textarea that I want to be a ckeditor.
To create a new event handler on a control you can do this c.Click
I create new ASP.NET web application that use SMTP to send message. The problem
I have the following code to create and apply a few styles for a
I'm trying to create a textarea that can contain multiple colors. I created a
Programming a Python web application, I want to create a text area where the
I would like to create an editable textarea with text highlighting (e.g. different colours,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.