How do I enable the Java Access Bridge in a bundled JRE?

Viewed 4996

In Java 1.7, the Java Access Bridge is bundled from start. It says that all you need to do is to run jabswitch.exe -enable to enable the JAB for this particular JRE.

This works fine when you get your JRE from the installer. However, when deploying a Java application for Windows only, you may want to bundle a JRE for easier installation. When the JRE is bundled, it seems impossible to activate the Java Access Bridge

Is there a way to enable the Java Access Bridge in a bundled JRE?

3 Answers

Doing jabswitch.exe /enable only changes some global parameter which is not identical for different versions of Java. In my case, it enabled Java 8 but not Java 7.

As it turns out, at least in Windows 10/11, it suffices to simply uncomment two lines in accessibility.properties in the subdir lib of each bundled JRE:

assistive_technologies=com.sun.java.accessibility.AccessBridge
screen_magnifier_present=true

Note: According to Microsoft it may additionally be necessary to disable the global switch: Enter in the Start menu "Optimize visual display" and then on the very bottom check off Java Access Bridge. In my case it worked irrespective of the global setting, so I assume the accessibility.properties takes precedence.

Related