'How to run uiautomatorviewer in java 11?

C:\Users\Shruti>uiautomatorviewer -Djava.ext.dirs=C:\Program Files\Java\jdk-11.0.14\lib;..\lib is not supported. Use -classpath instead. Error: Could not create the Java Virtual Machine. Error: A fatal exception has occurred. Program will exit.

First I had java 15 but I heard java 8 is compatible for uiautomatorviewer but it didn't helped then I uprgaded it to java 11 but same issue plz help



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source