Usually those things use the "display" property. If it does, then try "inline" instead of "block". If you are using a DIV (causes a line break), switch to a SPAN instead.
You are confusing "visibility" with "display". The "visibility" property is either "visible" or "hidden". The "display" property can be "inline", "block" or "none".
I don't see where the vars "rows" and "cols" get initialized, so they are probably null.
This appears to be a typo. There should only be two "=", not three.
It would make a whole lot more sense for you to post your code and let someone here try to fix it. You have already apparently found code that someone "knew for sure actually does preload the image"...
The IFRAME is still a window and has a name and can be targeted regardless of what file it is in. If it is open, then it will be targeted. If it is not open, a new window will be opened with that...