# Stuck on Bitmap loading

**URL:** https://forum.kirupa.com/t/stuck-on-bitmap-loading/319818
**Category:** flash
**Created:** [March 5, 2011, 1:44pm UTC](https://forum.kirupa.com/t/stuck-on-bitmap-loading/319818 "2011-03-05T13:44:35Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![abakiz](https://avatars.discourse-cdn.com/v4/letter/a/9fc348/32.png) [@abakiz](https://forum.kirupa.com/u/abakiz)
#### Post date: [March 5, 2011, 1:44pm UTC](https://forum.kirupa.com/t/stuck-on-bitmap-loading/319818/1 "2011-03-05T13:44:35Z")

</div>

Basically what I’m trying to do is load a Bitmap from a URL Request. 2 problems really.

1. the mLoader.width and height doesn’t return anything
2. When I input the loader manually, nothing comes up just some dots on the screen.

It’s part of a vehicle class, I’ve been searching hours on end for a solution. Even copy and pasted code. Nothing works…

I’m in urgent need of a fix, so any help is much appreciated.

```auto

		public function loadBitmap(pURL:String) : void
		{
			mLoader.load(new URLRequest(pURL));

			mHeight = mLoader.height;
			mWidth = mLoader.width;
			
			trace(mHeight, mWidth);
			
			loadCompleteHandler();
		}
		
		//Called automatically from loadBitmap
		private function loadCompleteHandler() : void
		{
			var BitmapData1:BitmapData = new BitmapData(mLoader.width, mLoader.height);

			BitmapData1.draw(mLoader);
			
			mPicture = new Bitmap(BitmapData1);

		}

```

and in the main.as

```auto

TestCar.loadBitmap("http://www.clker.com/cliparts/d/e/2/8/11949846071340700778car_ride_ganson.svg.thumb.png");

```
