I am successful in taking snapshot and open a activity using monkeyrunner. But what I want is to press a Button. So I am using ViewClient, but whenever I run my jython script the error comes:
File "F:\Example\AndroidViewClient\src\com\dtmilano\android\viewclient.py", line 870, in _init_()
File "F:\Example\AndroidViewClient\src\com\dtmilano\android\viewclient.py", line 986 in _ViewClient_obtainAdbPath
raises exception
('adb="%s" is not executable. Did you forget to set ANDROID_HOME in the environment?' %adb)
Exception: adb="%s" is not executable. Did you forget to set ANDROID_HOME in the environment?
Thanks in Advance
What OS are you using? Well, depending on your OS, you need to tell it where your Android SDK is located. For example, in Ubuntu machine, I have the following line in my .bashrc:
ANDROID_HOME=/home/roberto/android-sdk-linux/tools:/home/roberto/android-sdk-linux/platform-tools
export ANDROID_HOME
PATH=$PATH:$ANDROID_HOME
export PATH
If you are on a Windows machine, then you need to add this path to your Windows Environment's PATH.