the javascript:alert code that is being dynamically created ONLY works if I use the global object reference, gvo_Z.
But I would prefer to use either this (or a proxy to it such as lvo_this).
<div id = "target_div" ></div>
<script language="javascript" type="text/javascript">
function c_A( )
{ this.om_A = function()
{ return "got it" ;
} ;
} ;
function c_Z( )
{ this.pvo_A = new c_A() ;
this.om_Z = function()
{
var lvo_this = this ;
var lvs_html = "<div onmousedown='javascript:alert( gvo_Z.pvo_A.om_A() );' >press me ... WORKS ... uses global reference</div>" ;
lvs_html += "<div onmousedown='javascript:alert( lvo_this.pvo_A.om_A() );' >press me ... does NOT work ... uses THIS reference</div>" ;
document.getElementById( "target_div" ).innerHTML = lvs_html ;
} ;
} ;
var gvo_Z = new c_Z( ) ;
gvo_Z.om_Z() ;
</script>
add a function to your created element.
you can create your element with a name tag like this