Gnanu

Gnanu

  • 1.7k
  • 52
  • 9k

Window.Close() in MasterPage

Apr 16 2019 8:09 AM
var exit = confirm("Do u want to close browser!");
if (exit) { window.close() }
else { }
 
If user clicks yes then i need to close browser but Window.close() is not working
its showing 
"Scripts may close only the windows that were opened by it."  
Its from Master page.
Is their any other way to close the browser with the help of javascript. 

Answers (3)