Forum Discussion
Hi community,
I guess nobody can follow what I try to solve here. I will try anyway.
One ugly solution is to wrap the context item id into the window name and then later extract it from the tab. Something like this:
---
// Get current id
var currentItemId = document.thisItem.getID();
aras.uiOpenEmptyWindowEx(newItem.node);
var newWindowName = aras.mainWindowName + "_" + newItemId + "context" + currentItemId;
---
But I really don´t like this variant. I would prefer a variant where I can pass my item within the call:
var newWindow = aras.windowsByName[newWindowName];
newWindow.frameElement.src = "./test.html";
newWindow.frameElement.myItem = document.thisItem;
Unfortunately this one didn´t work. I weren´t able to pass custom variables to the frameElement. If I want to do, I would have to modify the codetree file behind it to allow my own properties to be passed. Which I also don´t want to do.
There has to be an easier solution...