Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8751497
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T13:03:30+00:00 2026-06-13T13:03:30+00:00

I know I can install an Android application programmatically by the below code which

  • 0

I know I can install an Android application programmatically by the below code which passes the URI of an APK file. Can I install the application without passing an APK file URI? For example, getting the byte array of an APK file and installing it?

File appFile = new File("application.apk");
Intent installIntent = new Intent(Intent.ACTION_VIEW);
installIntent.setDataAndType(Uri.fromFile(appFile),"application/vnd.android.package-archive");
startActivity(installIntent);
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T13:03:35+00:00Added an answer on June 13, 2026 at 1:03 pm

    When you install an application this way, you aren’t actually directly installing the application. What happens is that you start the installer and pass the installer a reference to the APK that you want to have installed. The installer isn’t part of your application code and has no access to the memory in your application’s process.

    The only way to do this, if you have a byte array containing the APK, would be to write the byte array to a file and then start the installer and pass it a URI that points to the file that you’ve written. Once the installation is complete you could then delete the file (so as not to leave random garbage on the user’s phone).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to make my android application as executable file that can install in
How can I install an application without any developer tools (Eclipse, Android SDK tools)?
I've been trying to get an android application to install an APK on the
if we develop our Android application with target Android2.1-update1,can we install that application in
I know I can use install-data-hook to do anything I want after my data
I would like to know if I can install IIS 7.5 on Windows Server
I was able to download an apk file and stored it in my /data/data/com.android.myApp/anotherApp.apk.
I am new to Android. I need to know how to install it in
Description I have two android application and here are the packages in which they
I would like to know how it is possible to protect an Android application

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.