Strange line reference In an Error

I get this error:

1046: Type was not found or was not a compile-time constant: progressBar.

and the source is:

import flash.text.TextField;

it looks like there is something i don’t undrstand can any one tell me what that is?

here’s the whole preloader class:

package 
{
    import flash.display.MovieClip;
    import flash.display.LoaderInfo;
    import flash.text.TextField;
    import flash.events.Event;
    import flash.events.ProgressEvent;
    
    public class Preloader extends MovieClip
    {
        /* Variable to store dataTextField param in the constructor function */
        
        private var dataTextField:TextField;
        
        /* Start function */
        
         public function setLoaderInfo(ldrInf:LoaderInfo):void  
         {  
             ldrInf.addEventListener(ProgressEvent.PROGRESS, onProgress);  
             ldrInf.addEventListener(Event.COMPLETE, onComplete);  
         }  

        /* Set the percent loaded to the textfield */

        private function onProgress(e:ProgressEvent):void
        {
            /* Bytes related local variables  */
            
             var percent:int = Math.round(e.bytesLoaded / e.bytesTotal * 100);  
             progressBar.width = percent / 100 * progressArea.width;  
             percentageText.text = percent + "%";  
        }

        /* Here you can send to another frame/scene or load any other thing */

        private function onComplete(e:Event):void
        {
            /* Remove listeners */
             dispatchEvent(e);
            //this.loaderInfo.removeEventListener(ProgressEvent.PROGRESS, onProgress);
            //this.loaderInfo.removeEventListener(Event.COMPLETE, onComplete);

            //Do something
        }
    }
}