<html>
<body>
<div id="output"></div>
<script>
function jExgTrend(){
}
jExgTrend.prototype.Start = function(text)
{
//this must return Instance name : "TestObj"
var InstanceName = "TestObj";
document.getElementById("output").innerHTML = "<a href=\"javascript:"+InstanceName+".Notify('"+text+"');\">"+text+"</a>";
}
jExgTrend.prototype.Notify = function(msg)
{
alert(msg);
}
var TestObj = new jExgTrend();
TestObj.Start("Text of the link");
</script>
</body>
</html>
How can I do something like this ? the method "Start" should return the name of the Instance of the class.
The problem is stupid I know :-(