How do I install an APK file using Android Studio? - android

I have an APK file and my developer assistant said to use it to install the app onto my phone, question is, how can I do it? Just click run? I think I tried it and it's not working, only the workshop files were editable ones and could run.

if you have ADB (android debugger) installed and set as environment path:
1st option:
i'd use that from cmd line. First you have to setup unknown sources from Settings menu and enable developer mode, and then trust USB Debug Options from your device. Go to system and you have to tap the version number a few times, you can google this. (That's how it used to be).
From Mac/Windows/Linux:
type:
To see if it's in path it should give you help:
adb
To enumerate devices connected via USB
adb devices
To install apk on your local machine to device (force install)
adb install -r ~/Desktop/some.apk
Or in Windows you can put your full path (force install)
adb install -r c:\Users\something\Desktop\some.apk
2nd option:
You can put APK on google drive, or some website you can access, even one drive or via email, then you can save it onto your device. Using ES File Manager, or some files manipulation tool, you can install it directly from there.
3rd option:
Use Google Play Beta or Alpha delivery methods. You can do a closed or open beta, and post it up there. That way all you need is a play.google link and then you will be able to install it, and manage updates via this method. I use this as I test alpha/beta APK Android Game deployment, and am able to distribute a URL (for open beta/alpha), and users can easily test it via this method. Amazon App Store and iTunes App Connect (iOS) has similar type options, too, but I'm just assuming you would distribute this App/Game via Play.
Remember if it's unsigned apk, you need to be able to enable side-loaded apks via your settings, app sources. If it's signed by a trusted developer then this shouldn't be a problem.

If you have an APK file you don’t need android studio.
Copy the file to the device you want to run it on and open it. You’ll be promoted to either enable developer mode or trust the app as a one off occasion.
You’ll then be given the option to install the app.

First you need to turn on "download from other sources" or something(I can not remember the option exactly) from your phone's setting. You can upload the apk file to google drive. And navigate to the directory use you phone, click and download file. And then you should be able to run and install the app to your phone.

Try PdaNet+.
It will easily install android studio application to your android mobile.
Download PdaNet+ for PC.
In mobile open Debugging.For Debugging go to Settings -> About phone -> SoftwareInfo -> Build Number -> Click 7 to 8 times on Build Number.It will open Developer Option.Go back to Setting there you see Developer option.Then in Developer Option search for USB Debugging and open it.Then connect your mobile to PC with USB.
Insatll PdaNet+ it ask to connect mobile,connect it with USB it will download mobile software.
After completing your program,in Android studio click on 'Run App' (Green symbol as Play Button) then it will show your Android Mobile in Connected Device.Then it will install Android Studio application to your mobile.

Related

Unity Build and Run aab file - nothing happens

I am using unity addressables for on-demand packs and also using google instant play plugin to build an instant app. I am using the unity's Build Settings -> Build and Run with my device connected. I have developer debugging enabled and the device is connected via usb. The aab file is built and saved on my local machine and when the build completes, nothing happens on the device. Shouldn't the game just start on the phone? When I search the phone, the app is also not anywhere to be found.
Any solutions?
So here is more of a workaround for this problem. The real solution needs to come I believe from either Unity or Google teams.
FIX:
Go to File -> Build settings -> player settings
Change the Company Name: com.yourname.currentname (to something else). Let's say: com.yourname.currentname2. And do the same for the packagename under "Other Settings".
Build and Run (having the device connected via USB and USB debugging enabled)
It should work. If still doesn't, make sure you uninstall your game (assuming you had it installed before on the device). If not installed, install it from the google play store or from an older apk, open the app info and clear all cache and data. Then uninstall it. Try the above steps for the fix.
On my side, I already had a published google play store app and now building an instant app for the same build. I uploaded a few instant app versions on the play store and installed them on the device. At that point I am not sure how google play handles the different versions (installed and instant one) and something terribly gets messed up. Is it caching some files somewhere? So aiming at a clean state is the key.

Newbie help for installing app on Android device

I'm working on developing my first mobile app on the Appery.io platform. I'm just about done building the app and need to beta test it for Android.
Appery lets you generate an Android certificate and export your app as a .apk file. I have my .apk file and I want to install it on my friend's phone. Is there anything else I need to do or can I install the .apk file? How do I go about actually getting it installed on the phone? It's not clear from the site's instructions how to do it when using a platform that generates the .apk file for you.
The easiest solution is to email the APK file to your friend. Then click on the attachment on your friend's phone. Alternatively, you can install the Android SDK and use its adb tool.
You can send it via Bluetooth or Share it on Dropbox, Google Drive, etc. When you install the app be sure that in the phone settings the "Install apps from unknown publisher" is checked. And don't verify the app with google play. Just click package installer.
There are several ways to install apk like:
send apk as attachment to your friend and open the attachment on their device.
copy the apk to their device and open it using any file manager, it will lead to install it.
send apk whiya bluetooth/ wifi tethering etc and open it on their device.
upload it to any file hosting website and open that link in their device using any web browser and download and install further.
if that device is with you, you can use adb.exe tool with following command "adb install your apkfile"
Note: but to use any of these ways, their device should have enabled "Install from Unknown sources" in their device settings->security.
Or alternately best approach:
upload your apk to GooglePlay Store and they can install it from there hassle free.

How to run an Android app which will run in any system without using Eclipse

I have created an Android Calculator app in Eclipse. If I want to run my app I need run it through Eclipse. But I want to run my app without Eclipse in any system as normal apps run, just download it and run.
If any one knows how to do this, please help me.
You probably want to take the .apk file in your bin folder. This file is your entire app packaged together.
You can run & install this on other Android phones, but they will have to have enabled "unknown sources" in application settings.
Otherwise, you'll have to publish to the app store, from where the entire world that owns an Android device can download it directly.
app run without eclipse in any system as a normal apps run
may I know how the normal apps run?
it need any emulator or device.
you can run the .apk file without eclipse also!.
download the Android SDk and create an emulator thru avd command and install any app.
the other way you can do by 3rd party software called BlueStacks App Player
this software is only for mac and Windows download here
Inside bin folder of your Calculator app project located on Hard disk there will be .apk file which you can transfer to your device then open file browser whichever you have that will allow you to install and run your application cheers.
Do you mean you want to install it on any device from your system, without the need to run Eclipse?
The command would be something like "adb install bin/MyCalculator.apk". Once you do that, your app is installed just like any other.
Do you mean you want anybody to install your app on their device? Your best bet is to just put it on the Android Market. Don't forget to generate a real signing key (don't use the Eclipse debug key) and sign your app properly before uploading it to the market.
If you don't want to use the market, then you can put the apk file on any web page, and have people download it with their browser. Then they go to their device settings and enable "Unknown sources". After that, they can run their browser, go to "Menu > Download" and select the apk they just downloaded.
Or, you can send the apk file to someone directly, and have them attach their device to their computer, enable USB, and copy the apk to their /sdcard directory somewhere. Then they launch a file browser (they'll have to install that first) and navigate to the apk file. I think that will allow them to install the apk on their device.
I think that should cover it.
You should generate the .apk file, and install it on any device you want..
http://www.technobitez.com/how-to/create-apk-files-for-android-phone
How to build an APK file in Eclipse?

Is there a way to debug an android application on the phone without the USB connection?

Is there a way to install an application I'm in the middle of development on to my phone without going through all the steps of signing it, releasing it etc.? (Without the phone being connected by USB)
I'm still very much mid-development, but I need to demonstrate the progress I've made so far to other members of my team away from access to my development environment, so I need to install it on my phone.
Inside your project bin folder there is an apk file. If you copy that file to a device you can then install the app from it.
When I am in your situation I throw my apk into dropbox and send out links for people to download it.
You can try adb wireless http://www.helloandroid.com/content/connect-your-android-phone-adb-wireless
But i don't really see why you cannot export and install an unsigned app?
At&t (and possibly other carriers) set up the firmware to prohibit sideloading, so you need USB connection if that is your carrier. Otherwise, just put the apk on a web site and enable installation from unapproved sources.
See for the purpose of debugging you can use the adb-wireless which provides the same functionality as the use of a USB.
Also for installing it on the phone directly you can try this and see if this helps.
Go to Settings -> Applications
Select the Unknown sources option. This allows you to install apps on your phone even if the app is not released into the Android Market.
If you are using Eclipse or any other IDE just click on the project and run as android application. The app shall get installed directly. ( Installation shall not depend upon whether you are using adb-wireless or a USB)

steps to install new android application onto new htc device

I need to install an android application running in my local machine on to my new android htc handset, how to do this,and i also need to give this application to someones htc device who is not near to me.
On your device, go to Settings > Applications. Tick Unknown sources. Go to Development. Tick USB Debugging.
Connect your device to your PC via USB cable.
If using Eclipse, when running your application you should get a dialog asking you which device to use where you'll be able to select your phone.
If not using Eclipse, build your app to an APK file (it mustn't be signed) and run adb -d install /path/to/myApp.apk in a terminal or command line
Send the .apk and these instructions to your friend.
Another easy way to do this, without an USB cable. Upload your .apk to somewhere on the internet, and make your friend visit the link with his browser.
Ex. http://mydomain.com/apk/myappk.apk
He will automatically download the app and be promptet for install.
He needs to enable application from unknown sources. It does not need to be signed. (step1 from Felix)
#Felix applications are indeed signed using a debug key during development.

Categories

Resources