Archive for the ‘Android’ Category

Different Ways to Install Applications On Android Without The Market

Installing apps on Android is relatively straightforward with the Android Market. You search for an app, select it and click install. However, there are often times when you may want to install a newly released app or an app that is not available in the Android Market. In these cases you will usually have to manually download and install an .apk file. An .apk file behaves in a similar manner to a “.exe” file on Windows, you need to copy it to your device and run it. Here are some ways that you can manually install an application without going through the market.

Enable Unknown Sources

Before attempting a manual installation of apps using the .apk files, you must first allow your phone to install from “Unknown Sources” (i.e. non-Market apps).

To do this, navigate to Menu -> Settings -> Applications and check the box marked “Unknown Sources“.

apkinstaller-unknown

1. Installing app Using The Conventional Method

Step 1: Install File Manager

Android does not natively come with any method of browsing the data on your SD card, so you will need to install a file manager from a market. There are a large variety of file managers available on Android, but my personal favourite is ASTRO File Manager.

astro file manager-main

Step 2: Copy .apk file to SD card

Once you have ASTRO File Manager installed, connect your Android device to your PC using your USB cable. Mount the SD card and copy over the .apk file you would like to install.

Step 3: Install .apk

On your Android device, navigate to the .apk file using ASTRO File Manager and select it.

This will open a dialog box allowing you to install the app. Select “Open App Manager“.

apkinstaller-app

On the next two pages, select “Install” and “Install” again to install the .apk.

apkinstaller-installapp

apkinstaller-appinstall

Your new app is now installed.

2. Installing app using Dropbox

Dropbox is really a versatile app and is a waste if we don’t fully utilize it. The method is simple. In your computer, download the apk file to your Dropbox folder. Let it finish syncing. In your phone, open the Dropbox app, navigate to the folder where you keep the apk file, click on it. Dropbox will then download the apk file. The usual installation follows.

3. Installing app Using the Online Apk Installer

The online apk installer is a web app created by a helpful XDA-Developers forum member htc-hd2, with the aim to make manual installation of an .apk file much easier. It is useful if you want to share an apk file with a friend.

Step 1: Upload File

First, navigate to www.apkinstall.com.

Here you will see a black “Browse Files…” button. Select this and choose the apk file on your PC.

apkinstaller-browse

The apk file will remain active on the website for 15 minutes.

Step 2: Scan QR Code

Once you have uploaded the file, a QR code will appear on the website.

apkinstaller-qrcode

You must scan this QR code with a Barcode Scanner. The website suggests using Barcode Scanner, however I personally prefer using Google Goggles.

apkinstaller-barcode

Once the QR code has scanned, you can click on the link to download the .apk file straight to your device.

Step 3: Install .apk

After the .apk file has downloaded to your Android device you can install it by simply clicking on it and navigating through the installation pages.

apkinstaller-download

Conclusion

Most users will probably be comfortable using the conventional method of installing Android apps. However, if you have a less tech-savvy friend who you want to share an apk with, you can always remotely upload it and send them the QR code to scan using their phone. This way they will not have to fiddle around with copying the apk to their phone and opening it using a file manager.

Let us know in the comments if you have been able to use this tool.

How to sign Android APK file using command line

To sign an APK file using Command line utility, is a three step process and is easy and simple to learn.

To sign an Android APK from command line use: –

  1. Sign the APK with jarsigner (using default keystore, android-root is the alias of the signing key):
    $ jarsigner -signedjar HelloWorld-new.apk HelloWorld-debug-unaligned.apk android-root
    Enter Passphrase for keystore: password
  2. Verify signature (optional)
    $ jarsigner -verify -verbose -certs HelloWorld-new.apk
  3. Align the APK (must use -v 4 option):
    $ ~/android-sdk-linux_86/tools/zipalign -v 4 HelloWorld-new.apk HelloWorld-new-aligned.apk

Android – How to install .apk files in Android Emulator in windows?

This tutorial will explain how to install application files (.apk) files in Android Emulator in Microsoft Windows.

Step 1: Downloading the JDK (If you have completed this step or your system has Java JDK, please skip this step and go to steps 2)

  1. Point your browser to http://java.sun.com/javase/downloads/index.jsp. The Java SE downloads page appears.
  2. Click the JDK link under the Java platform (JDK) heading (see below)
  3. Using the Platform drop down list, confirm your platform, and then Click the download button.
  4. Click the skip This step link at the bottom of the page.
  5. Click JDK-6u20-windows-i586.exe to download the file
  6. In the save as dialog box, select the location where you want to save the file and click save.

Step 2:  Download and Install the Android SDK (If you have completed this step or your system has Android SDK, please skip this step and go to steps 3):-

First download the latest version of Andorid SDK from the official website of google. Here is the link and screenshot of the official website.

Download latest version Android SDK

Then install the SDK starter package. Make sure to update the SDK and install the proper platform version. In this tutorial we downloaded and installed the SDK to the windows folder location “C:/Program Files/Android/Android-sdk”.

Step 3: Launch AVD Manager

In windows go to Start -> Programs -> Android SDK Tools -> AVD Manager. Your AVD Manager will be launched as shown below.

Now create an new AVD (virtual device) with suitable platform(API and version).Click “New” Button and select Target, Click “Create AVD” button as shown below.

Now your new AVD is successfully created as shown below.

Now launch your emulator by clicking the “Start” button in AVD Manager.

Now it will launch your Android Emulator as shown below.

Step 4: Get your .apk file

Manually copy and paste your .apk file into the destination folder “C:/Program Files/Android/Android-sdk/platform-tools/”.  otherwise if you don’t have platform-tools folder, then copy it into “C:/Program Files/Android/Android-sdk/tools/”.
If you don’t have one, download the following .apk file (i.e AGF Sample.apk) which i am going to install here

Download AGF Sample.apk

Step 5: Run the adb command

Go to Start ->Run ->command

Type the following code:

cd C:/Program Files/Android/Android-sdk/platform-tools (i.e. my adb.exe is located in this path but in some cases it is located in “tools” folder then type the following code “cd C:/Program Files/Android/Android-sdk/tools”)

and run the command adb install AGF Sample.apk as shown below. That’s it.

.apk file is successfully installed.

and will get the message like the picture given below (the given picture is for another application named family room):-

during this step if you get any sort of error regarding Emulator, then please confirm your emulator is running and is having desktop on the top (you are able to see watch, all menus and a wallpaper over it)

thats it you have finished installation of your new application over android. now lets check our application for tests.

Step 6: Check your application on emulator.

Open the Android Emulator and you will find AGF Sample application installed on the emulator as shown below

That’s it.

How to Uninstall APK Files from Android Device Emulator

In our previous tutorial “How to Install APK Files on Android Device Emulator” we described how to install step-by-step an APK package on the emulator. Today we want to briefly cover how to remove already installed applications.

Note: Google explains that in short here: http://code.google.com/android/intro/installing.html#uninstalling

To perform this operation you would need (how logical) the emulator itself, which is shipped with Android SDK. Once again, you don’t need Eclipse development environment neither for installing and testing of Android applications nor to remove it from the emulator.

Ok, so you have a working SDK with emulator. In the SDK’s main directory (in the last how-to we called it “$SDK_ROOT”) there is the folder called “tools”. You need to start the console terminal (“Start -> Run… -> type ‘cmd'” for Windows PCs). Type-in the following command: adb shell rm data/app/$APK where $APK is the name of the APK file. For example if you want to uninstall the Snake game, you should type this: adb shell rm data/app/Snake.apk

That’s it. Now you can install your Favourite APK again 🙂

How to Install APK Files on Android Device Emulator

In this tutorial we want to explain how to install APK-files to an Android device emulator. Thus you will be able to test already now all new application which will start to appear soon. When the actual Android-powered devices will appear (approximately beginning of 2008), they must be also compatible with already available till then applications.
For the whole experiment you will need two things:
a Windows, Mac OS X (intel) or Linux (i386) powered computer
the Android Software Development Kit (SDK).
You do not need Eclipse or Eclipse-plugin the Android Development Tools (ADT). The last two are required for the software development for Android, but are not necessary for application evaluation on emulator.
At first let’s go and download the Android SDK, which may be obtained here: http://code.google.com/android/download.html
Follow the instruction, described in the topic “Installing SDK” from the Google manual, which is located here: http://code.google.com/android/intro/installing.html#installingsdk
For your convenience we copied the relevant steps here:
-=-=-=-=-=-=-=- Extracted from Google manual -=-=-=-=-=-=-=-
Installing the SDK
After downloading the SDK, unpack the .zip archive to a suitable location on your machine. For the rest of this document, we will refer to the directory where you installed the SDK as $SDK_ROOT.
Optionally, you can add $SDK_ROOT/tools to your path:
On Linux, edit your ~/.bash_profile or ~/.bashrc file. Look for a line that sets the PATH environment variable and add the full path to your $SDK_ROOT/tools to it. If you don’t see a line setting the path, you can add one:
export PATH=${PATH}:
On a Mac, look in your home directory for .bash_profile and proceed as for Linux. You can create the .bash_profile, if you haven’t already set one up on your machine.
On Windows, right click on My Computer, and select Properties. Under the Advanced tab, hit the Environment Variables button, and in the dialog that comes up, double-click on Path under System Variables, and add the full path to the tools/ directory under $SDK_ROOT to it.
Adding $SDK_ROOT/tools to your path lets you run Android Debug Bridge (adb) and the other command line tools without needing to supply the full path to the tools directory. Note that, if you update your SDK, you should remember to update your PATH settings to point to the new location, if different.
-=-=-=-=-=-=-=-=-=-=-=-=-=-=–=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Now navigate to the $SDK_ROOT/tools directory and execute the file ’emulator.exe’. This is the Android emulator itself. Wait couple of minutes until it loads. Now you must see the home screen of Android – wallpapers with snowy mountains on the background and the navigation bar below.
Enjoyed? Ok! Let’s continue. Download and save locally a APK-file which you want to install/evaluate on the emulator. We recommend to save the APK file directly in the $SDK_ROOT/tools directory.
Note: APK probably stands for “Android package”. It’s an application distribution unit in the Android environment. If you are coming from the Windows Mobile world, think of APK as of CAB-files.
Ok, now start the console (“Start -> Run… -> type ‘cmd'” for Windows computers). Type-in the following command: adb install $APK where $APK is the name of the APK file. For example: adb install Snake.apk
If you receive a “path not found” error, then you probably either didn’t add path to the $SDK_ROOT/tools directory to your system PATH settings or the application you are trying to install is not in the $SDK_ROOT/tools directory.
If all went without errors then you should be seeing your newly installed APK on the emulator.

Enjoy Android!

%d bloggers like this: