I have this little HTML file. What I need is when there is a heavy flash object which effect on page load time, I want to show the static image and then once the swf file is fully loaded need to swap the flash object and static image seamlessly.
I have just added doStuff method to hide the swf content. But this is not the solution
Any idea how to do this and approaches really appreciate.

<script type="text/javascript">

function doStuff() {
window.status = "Page is loaded";
document.getElementById("statImage").style.display = "none";
document.getElementById("flashObj").style.display = "block";
<body onload="doStuff();">
<div id="lnTag">
<img id="statImage" src="images/stat_bg.jpg" alt="" width="350" height="200" style="display:block"/>
<embed id="flashObj" src="FlashGallery.swf" width="350" height="200" style="dsiplay:none"> </embed>