Detecing Image Before Loading

Is it possible with actionscript to detect if an image is present before loading it?

For instance I am using loadMovie to load an external jpeg.

instanceName.loadMovie("/folder/image.jpg");

Is there any way I can test to see if that image exists using Actionscript, then tell the timeline to do something else if it is not there?

checkImageExist(“Images/test.jpg”);
function checkImageExist(imageURL) {
//--------------- image url from the attribute of the component -----------
//----------- loadvars are used to check the whether the image exists are not ----------
var imageURL = imageURL
var imgLoadVars = new LoadVars();
imgLoadVars.load(imageURL);
imgLoadVars.parent = this;
imgLoadVars.onLoad = function(success) {
if (success) {
trace("-------- Image exist ---------------"+imageURL);
mcImgHolder.loadMovie(imageURL);
startEnterFrame();
} else {
trace("-------- Image does not exist ---------------");
}
};
}