Image.onload() will often work.
To use it, you'll need to be sure to bind the event handler before you set the src attribute.
Related Links:
Example Usage:
window.onload = function () {_x000D_
_x000D_
var logo = document.getElementById('sologo');_x000D_
_x000D_
logo.onload = function () {_x000D_
alert ("The image has loaded!"); _x000D_
};_x000D_
_x000D_
setTimeout(function(){_x000D_
logo.src = 'https://edmullen.net/test/rc.jpg'; _x000D_
}, 5000);_x000D_
};
_x000D_
<html>_x000D_
<head>_x000D_
<title>Image onload()</title>_x000D_
</head>_x000D_
<body>_x000D_
_x000D_
<img src="#" alt="This image is going to load" id="sologo"/>_x000D_
_x000D_
<script type="text/javascript">_x000D_
_x000D_
</script>_x000D_
</body>_x000D_
</html>
_x000D_