Hello (sorry for my bad english, I am French).
You have two problems:
1/ the "unable to connect" problem (I have the same issue, and have not really found a good solution for it, because the modification of grants in the Java security.policy file doesn't solve it. However, I will try to solve the second point).
2/ the "please check this file is opened in another program" when trying to save the modified Java security.policy file.
For the second problem, the file is a READ ONLY file, and you can do the following to modify it (I work with Window 7 and in French version, so it is possible that my advice should be slightly modified).
Right click on the folder containing the file you try to modify. Select properties.
you can see that "read only" box is checked.
Uncheck the box. But unchecking the box doesn't solve the problem of the impossible saving.
You have to click on "security" tab.
Near the top of the window, select "users" (instead of system, administrators and trustedInstallers).
Click the "modify" button (it means "modify the authorisations"). You have a new window open.
Click "users" (which means "ordinary users").
At the bottom of the window, you have a frame "Authorisations for Users".
Check the box "Total control" / "Authorise".
Click OK.
Click OK.
A window "confirmation Attribute Changes" is open.
Check the option "apply the modifications to this folder, its subfolders and to the files".
Click OK.
Click OK.
Now, you go back to the file you want to edit.
Right click it and select properties.
Uncheck the "read only" box.
Click OK.
In principle, you can now edit and save your file. I have no solution today for point 1/ but let me know if you have a solution that works, and if the point 2/ works well.