Problem with VBScript CreateObject?
However, I have noticed that if the browser (IE in this case) is not closed the object OCX file cannot be deleted and unregistered. I thought in VBScript it is sufficient to set the object to "nothing" to release it? Or is there more I have to do to "unload" the object?
Here's my code please tell me what I'm doing wrong here:
---------- CODE STARTS HERE ----------
<script language="VBscript">
Function isObjectValid()
on error resume next
Set TestObject= CreateObject("TestObject.MyObject")
isObjectValid= IsObject(TestObject)
Set TestObject= nothing
End Function
</script>
<SCRIPT LANGUAGE="JavaScript" FOR="window" EVENT="onLoad()">
if (isObjectValid())
document.write(" Valid object!");
else
document.write(" Not valid!");
</SCRIPT>
---------- CODE ENDS ----------

