PDA

View Full Version : new LzLibrary() - can't get to work


redcoat
09-15-2005, 12:07 PM
Hi,

I have the following little test to load a library dynamically, but can't get it working.

Can anyone help, please?

cheers,

David

<canvas width="800" height="400" debug="true">
<script>
function loadLib(){
Debug.write("loading library!");
var libName = "bluebox.lzx";
var foo = new LzLibrary(canvas);
foo.href = libName;
foo.load();
}
</script>

<button>Load It!
<method event="onclick">
loadLib();
</method>
</button>
</canvas>

bluebox.lzx is in the same directory and simply contains:

<library>
<view name="blueboxview" height="100" width="100" bgcolor="blue">
<button>heeloo</button>
</view>
</library>