I am trying to run UiAUtomatorViewer from command prompt on Windows10 machine. But it keeps giving the following error when I run uiautomatorviewer.bat from the Sdk\tools\bin directory.
-Djava.ext.dirs=..\lib\x86_64;..\lib is not supported. Use -classpath instead.
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
(image of above error for reference)
JAVA_HOME, ANDROID_HOME environment variables are set and I am able to use adb commands like adb devices etc well.
I also added Java install directory to the PATH variable. Any suggestions?