matt
15 years agoOccasional Contributor
Error viewing locals or inspecting an array of objects during debug
Using the code included below, set a breakpoint on the "Log.Message" line in function "bar". Run "bar". View the Locals window and expand array "a". The value for the first item will be:
"Error: Could not convert variant of type (OleStr) into type (Dispatch)"
Notice that you can correctly inspect the custom object in variable "b"...just not when it is included as an item in an array. Version of TC is 7.5.
function foo()
{
this.name = "myname";
}
function bar()
{
var a = new Array(1);
var b = new foo();
a[0] = b;
Log.Message(a[0].name);
}