# Importing a class works only in same folder

**URL:** <https://forum.kirupa.com/t/importing-a-class-works-only-in-same-folder/283424>\
**Category:** flash\
**Created:** [March 5, 2009, 10:09pm UTC](https://forum.kirupa.com/t/importing-a-class-works-only-in-same-folder/283424 "2009-03-05T22:09:31Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ozymandias](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/ozymandias/32/1997_2.png) [@Ozymandias](https://forum.kirupa.com/u/Ozymandias)\
**Post date:** [March 5, 2009, 10:09pm UTC](https://forum.kirupa.com/t/importing-a-class-works-only-in-same-folder/283424/1 "2009-03-05T22:09:31Z")

</div>

I have a class I made for a seekbar that looks like this:

```auto
package {
	import com.utility.formating.FormatTime;
	import flash.display.MovieClip;
	import flash.text.TextField;	
	import flash.events.*;
	import flash.geom.Rectangle;
	import fl.video.VideoEvent;
        import fl.video.FLVPlayback;

	public class SeekBar extends MovieClip {
		public var flvplayback:Object;
		public var percentPlayheadTime:Number;
		public var currentPlayheadTime:Number;
		public var totalPlayheadTime:Number;		
		public var seekTotal:Number;
		public var seekWidth:Number;
		public var dragging:Boolean;
		
		public function SeekBar(flvplayback:Object) {
			this.flvplayback = flvplayback;
			this.flvplayback.playheadUpdateInterval = 100;
			this.flvplayback.autoRewind = false;
			this.seekWidth = this.seekBackground_mc.width;
			this.percentPlayheadTime = 0;
			
			this.seekButton_mc.buttonMode = true;
			this.seekButton_mc.useHandCursor = true;			
			this.updateSeekPosition();

			this.flvplayback.addEventListener(VideoEvent.PLAYHEAD_UPDATE, this.updateData);
			this.seekButton_mc.addEventListener(MouseEvent.MOUSE_DOWN, this.seekButtonMouseDown);
			this.flvplayback.stage.addEventListener(MouseEvent.MOUSE_UP, this.stageMouseUp);
		}
	}
}

```

When I put the .as file in the same folder as my .fla and link it in the library using SeekBar for the path, it works. If I move it to my main classpath and link it using com.video.SeekBar I get the following errors when I try to run it:

1119: Access of possibly undefined property seekBackground\_mc through a reference with static type SeekBar.

Every reference to a movieclip is throwing the same error. Could someone explain what’s happening?
