I am trying to dynamically add to an existing model using the 3D Javascript API function addModel. I then attempt to get a reference to the item just added using the call scene.meshes.getByIndex(nodeIndex) where nodeIndex is the number of meshes before the add (obtained using scene.meshes.count before the addModel call). This usually returns a valid reference to the node that I then see in the 3DPDF view and in the model tree. The problem is that on some machines (particularly VM's) this is not always the case sometimes addModel adds to the meshes list (thus increasing the count) and sometimes it does not. On the machines where it works it appears to always work, on the others it appears to almost always fail.
Has anyone seen this type of behavior from the addModel function? Do you have any idea of how to get around it? Any suggestions would be greatly appreciated.
Thanks