1

Today I followed the Youtube for setting my laptop(linux-Debian) to install the android SDK tool , I have set PATH in environment variables via command line [terminal line]:

hauying@hauying-yoga-linux:~$ echo $PATH
/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/home/hauying/Android/tools:/home/hauying/Android/platform-tools

After setting the PATH successfully, I can't open "uiautomatorviewer". It shows following error when I try to open it: [terminal line]:

hauying@hauying-yoga-linux:~/Andriod/tools/bin$ '/home/hauying/Andriod/tools/bin/uiautomatorviewer' 
-Djava.ext.dirs=/home/hauying/Andriod/tools/lib/x86_64:/home/hauying/Andriod/tools/lib is not supported.  Use -classpath instead.
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.

I tried using command -classpath ,but it can't find this command.

How can I open my "uiautomatorviewer". Please help.

PRERNA PAL
  • 381
  • 2
  • 10
Howard
  • 109
  • 2
  • 11

1 Answers1

0

Please try the instructions on below websites. These might help resolve the issue:

  1. https://sansatechnology.wordpress.com/2017/11/20/how-to-fix-appium-uiautomatorviewer-issue/
  2. Workaround: https://discuss.appium.io/t/uiautomatorviewer-throws-error/11620/15
PRERNA PAL
  • 381
  • 2
  • 10
  • I have another question ,could you help me? – Howard Jul 22 '19 at 09:21
  • I would surely try my best. Please raise it as a separate question if it is not related to this question. The community is big and very helpful :) – PRERNA PAL Jul 22 '19 at 09:24
  • DON'T NEED ONE TO DOWNGRADE TO JAVA 8 . Please refer to solution given by me on this question: https://stackoverflow.com/questions/49072271/unable-to-launch-the-ui-automator-viewer/73725475#73725475 – Atul KS Sep 15 '22 at 04:02