views:

1313

answers:

3

Why the TextArea class is not available for my Flex Builder 3?

Project has flex32 SDK in buildpath. other imports are OK.

    import flash.display.*;
    import flash.events.*;
    import flash.geom.*;
    import flash.net.*;
    import flash.text.*;
    import flash.utils.*;

    import mx.core.*;
    import mx.controls.TextArea;

Severity and Description 1172:

Definition mx.controls:TextArea could not be found.

A: 

I use the sdk and FlashDevelop, and must configure classpaths to point to \flex_sdk_3.2\frameworks\projects\framework\src Otherwise, the compiler nor editor will find the classes. And, the compiler throws the same error. Perhaps Flex Builder is either encountering a conflict between classes defined and referenced in the framework.swc, or maybe the project's classpath could be set similar to FlashDevelop.

Michael Prescott
+2  A: 

My guess is that you created an 'ActionScript Project' instead of a 'Flex Project' so unless you explicitly add them, some packages and components won't be available.

The easiest workaround is to create a Flex project instead.

euge1979
A: 

import flash.text.TextField; :)

Joro