I'm unable to set package and activity in the appium

I Installed appium and opened appium.exe
If I try to set Package and Launch Activity, the dropdowns opens empty I can write/edit the dropdowns ???

Please help me out!!! I was searching this from a week :frowning:

1 Like

In the new version of Appium exe app, the app activity and package are identified by Appium to make it easier for users.

To solve this problem, please make sure that JAVA_HOME is set in your environment variables and that itā€™s pointing to your JDK home directory.

Also make sure that you add

C:\Program Files\Java\jdk1.8.0_25\bin

to your path variable in system variables. Do that and let me know how it works :smile:

Iā€™m facing the same issue for appium windows 1.3.4.1.
I have set the java home and bin folder in PATH already.
Could there be some other issue?
NOTE: Iā€™m using jdk 1.7

Are you choosing the application path?

To get the PackageName and ActivityName, first you need to choose the ā€œ.apkā€ file path. From the above image,
-> set the first checkbox ON
->then click on Choose button
-> Give the path of your apk file.

Then it automatically populates the package name and activity names.

Let me know if the doesnt help.

I had renamed the apk, this caused the error. Anyway thanks for the answer. Could you tell why renaming the apk from the original when is built causes this issue?
Thanks once again.

2 Likes

Hello HumbleAlchemy,

Your solution of renaming the file worked for me :smile:

Thank you so much.

Hi

If i dont have the apk file. Then how to get the package name and launch activity name?

Iā€™ve tried with renaming too but still the package dropdown is empty.
from command prompt when i user command >aapt dump badging xyz.apk then it shows the package name but its not showing any package name in appiuumā€¦please suggest.
The environment variables are also set.
Environment variable : C:\AppData\Local\Android\android-sdk\tools;C:AppData\Local\Android\android-sdk
Application path: C:\AppData\Local\Android\android-sdk\build-tools\22.0.0\xyz.apk

Please suggest any solution.

I am using apium v1.3.4.1 and my JAVA_HOME path is also correct

I didnā€™t have .apk but i do have their
package name: com.google.android.gms &
activity name: com.google.android.gms.ads.settings.AdsSettingsActivity
based on these i want to inspect elements displayed on the activity using inspector window

OR
is it possible to inspect element in inspector window when i run these package and activity from eclipse??
PLEASE REPLY

Hi,

after setting up environment variable for jdk and jre and also path. define ppath for SDK in appium and select APkā€¦andand you will see package name in thereā€¦

I have same issue with my windows 7

Iā€™m unable to set package and activity in the appium ,I set JAVA_HOME,ANDRIOD_HOME ,and Set the path too,

but still no luck,Please kindly help me out ā€¦

Please find screen shot:

When I am clicking the choose button the whole Android setting modal is getting closed and I am unable to select the file.Please suggest me that how I can fix this issue.

Hello Kanishka,

Greetings!!

I am new to appium- Mobile Automation, trying to make a simple mobile browser automation demo. My goal is to use appium with capybara along with Ruby, so that the appium inherits all capybara DSL. Please can you help me with any sample code, so that it can help me with start up. It will be a great help.

Thanks.

for blank appium package and activity drop down.
install API17 in android sdk manager

Hi , Am facing the same. I had added the environment variables and path in system variables. Still the package and activity drop down is blank. Can you please let me know. Its urgent, am trying this from 4 days.

@naazneen
Did you add ANDROID_HOME to system variables and both of the ā€œbuild-toolsā€ and ā€œplatform-toolsā€ to the path too??

The issue is with the space in the apk path. Make sure you donā€™t have space in your apk path.
Either remove space or put apk path in inverted commas.

1 Like

Has anyone found a solution to this issue?
Windows 7 machine
I have installed Appium 1.4.13.1
I have tried this on Java 1.8 and 1.7 and neither are working.
I have API17 installed as suggested
I have no spaces in my apk path:
C:\Automation\Android_Mobile_App_Repository\FlipKart_APK_3.1
I added ANDROID_HOME to system variables and both of the ā€œbuild-toolsā€ and ā€œplatform-toolsā€ to the path

I have the following as USER VARIABLES from setting up Selenium and Appium:
ANDROID_HOME C:\Program Files (x86)\Android\android-sdk
ANDROID_PLATFORM_TOOLS C:\Program Files (x86)\Android\android-sdk\platform-tools
ANDROID_TOOLS C:\Program Files (x86)\Android\android-sdk\tools
JAVA_HOME C:\Program Files\Java\jdk1.7.0_60
M2 %M2_HOME%\bin;%JAVA_HOME%\bin
M2_HOME C:\Program Files\Apache Software Foundation\apache-maven-3.2.1
Path
%M2%;
C:\Users\crhoads\AppData\Local\Apps\cURL\bin;
%ANDROID_HOME%\tools;
%ANDROID_HOME%\platform-tools;
%ANDROID_HOME%\build-tools;
C:\Users\crhoads\AppData\Roaming\npm

I added JAVA_HOME to the System Variables as I didnā€™t know if it needs to go in System or User Variables. It was originally only in User Variables, As well I added %JAVA_HOME%\bin to the System Variable ā€œPathā€. Is this needed as a System Variable or just the User Variables?
Either way before I added it and after I added it, still nothing available in the drop down menus.

I have the following as SYSTEM VARIABLES:
JAVA_HOME C:\Program Files\Java\jdk1.7.0_60
ANDROID_HOME C:\Program Files (x86)\Android\android-sdk
PLATFORM_TOOLS C:\Program Files (x86)\Android\android-sdk\platform-tools
TOOLS C:\Program Files (x86)\Android\android-sdk\tools;
Path
C:\ProgramData\Oracle\Java\javapath;
C:\Program Files (x86)\iis express\PHP\v5.4;
C:\Program Files\Apache Software Foundation\apache-maven-3.2.1\bin;
C:\Program Files\Java\jdk1.8.0_65\bin;
C:\Program Files\Java\jdk1.7.0_60\bin;
C:\Windows\system32;
C:\Windows;
C:\Windows\System32\Wbem;
C:\Windows\System32\WindowsPowerShell\v1.0;
C:\Program Files (x86)\OpenText\Viewer\bin;
C:\Program Files\Java\jdk1.7.0_60\bin;
C:\Program Files (x86)\Java\jre1.8.0_65\bin;
C:\Program Files (x86)\Android\android-sdk;
C:\Program Files (x86)\Git\cmd;
C:\Program Files (x86)\Microsoft SQL Server\110\Tools\Binn\ManagementStudio;
C:\Program Files (x86)\Microsoft SQL Server\110\Tools\Binn;
C:\Program Files\Microsoft SQL Server\110\Tools\Binn;
C:\Program Files (x86)\Microsoft SQL Server\110\DTS\Binn;
C:\Program Files\SeleniumBrowserDrivers;
C:\Program Files (x86)\IVI Foundation\VISA\WinNT\Bin;
C:\Program Files\IVI Foundation\VISA\Win64\Bin;
C:\Program Files (x86)\IVI Foundation\VISA\WinNT\Bin;
C:\Users\crhoads.dnx\bin;C:\Program Files\Microsoft DNX\Dnvm;
C:\Program Files\Apache Software Foundation\apache-maven-3.2.1\bin;
C:\Users\crhoads\AppD;C:\Program Files\MySQL\MySQL Server 5.1\bin;
C:\Program Files (x86)\Microsoft SDKs\Azure\CLI\wbin;%systemroot%\System32\WindowsPowerShell\v1.0;
%systemroot%\System32\WindowsPowerShell\v1.0;
%ANDROID_HOME%\tools;
%ANDROID_HOME%\platform-tools;
%ANDROID_HOME%\build-tools;
C:\Program Files (x86)\Microsoft ASP.NET\ASP.NET Web Pages\v1.0;
C:\Program Files (x86)\Windows Kits\8.0\Windows Performance Toolkit;
C:\Program Files\nodejs;
C:\Program Files (x86)\nodejs;
%JAVA_HOME%\bin

Any and all help is greatly appreciated.

Chris,

I have found a solution for this:

Apart from adding JAVA_HOME to your user variables, you also need to add the path to the java jdk to your PATH under User Variables. That should fix the problem.

Swaroop! That did it!

Thank you so much to you and the board for help!!!