In Chrome browser, not able to close the window Version 72.0.3626.109

Hi,

I am facing a challenge in closing a chrome browser window when user click on cancel button.

scenario is, If calculation is not done, and user click on cancel then system will show customised pop up confirmation (NOT confirmation message with button.) button "Yes" system will close the parent window since through the child screen I need to close the window.

If already calculated then directly close the window. 

for this I am use RunJavaScript server action 

SyntaxEditor Code Snippet

function CloseScreen() {
 open(location, '_self').close(); 
 setTimeout (window.close, 1000);
 window.close();
}

closing from child window used "window.parent.close()" 

Issue: chrome browser will refresh the screen, will not close the screen, and all the API written in preparation again.

can anyone please suggest, what is the mistake I am doing?


Hi Ravikumar,

Did you directly tried to close the current browser tab using only window.close()?

Can you check Console Logs, What error you are getting when you execute your script?
Please let us know if you are getting any errors or warnings in Console while executing your query.

Regards

Palak Patel wrote:

Hi Ravikumar,

Did you directly tried to close the current browser tab using only window.close()?

Can you check Console Logs, What error you are getting when you execute your script?
Please let us know if you are getting any errors or warnings in Console while executing your query.

Regards

Hi Palak,

Yes, I tried with test screen, it is working fine, and also I don't see any issue in IE,

there is no error in the logs and no warnings. 

Regards



Hi,

Can you provide a sample application where this issue is reproducible in Google Chrome?


It will help us to investigate the browser specific issue and come closer to solution. 


Regards,

Palak Patel