When I try to open window.open('file///C:\calendar.html')
it throws
Access Denied error
How do I fix this? Thanks
When I try to open window.open('file///C:\calendar.html')
it throws
Access Denied error
How do I fix this? Thanks
Usually you'll won't be allowed to open files from the client's filesystem as this would pose a huge security hole. No browsers would allow it.
You could use signed scripts to do that. For a detailed description check: http://www.mozilla.org/projects/security/components/signed-scripts.html This is of course browser specific.
Could it be that the colon is missing?
'file:///C:\calendar.html'
Edit: Might also need to do only two forward slashes, and escape the backslash: 'file://C:\\calendar.html'
. Not sure you can open local files via JavaScript though, like the other answer says.