Hi,
I have a custom component that causes a pop up window with buttons in it. The buttons actually call the actionservice view,edit etc. Now when the user clicks the button i want the action to be performed but the original pop-up window to close. I tried using javascript.
In my jsp page
<script type="text/javascript">
registerClientEventHandler(null, "invokeCrystal", invokeCrystal);
function invokeCrystal(theUrl)
{
alert(theUrl);
window.close();
}
</script>
In the button execute class in the component
ArgumentList args1 = new ArgumentList();
args1.add("url", "www.google.com");
setClientEvent("invokeCrystal", args1);
ActionService.execute("view", this.m_actionArgs, this.m_actionContext, viewpopup.this, null);
setClientEvent("invokeCrystal", args1);
The issue is that if i comment out my "ActionService.execute" for testing then the javascript works fine and the window closes but when i have the ActionService code then the action executes fine (view action for a document) but the original popup window doesn't seem to close.
Any ideas?
Thanks