Eclipse - Running the same project twice - android

I have managed to create my first app called RoomFinder and it works fine. I have now managed to create RoomFinderNFC which uses NFC technology. To create RoomFinderNFC I created a new workspace and imported/copied Roomfinder into a new workspace. My plan was to have RoomFinder installed on my phone as well as RoomFinderNFC. So I have both the apps installed to demonstrate the differences.
However when I run RoomFinderNFC from eclipse it installs over RoomFinder and vice-versa.
Is there a way to have both apps installed at the same time?
Thanks

You have to change your RoomFinderNFC app package name. After changing package name you can run both app on same device on same time. just you need to different different packages name in both app.
may this helpful to you :)

Related

Can the bundle-Identifiers of iOS and Android differ on Flutter?

I uploaded a test-release for an App on both iOS & Android on AppStore/GooglePlay using their respective native programs. In other words I reserved their bundle-identifiers string.
Now I'm trying to code the App using Flutter, which is freshly new to me.
Can I create a Flutter project (running on Android Studio) for this app and then change the bundle-identifiers names for each platform separately? and will it work so I could update these apps continuously?
For example,
One App created with a bundle-identifier for iOS like this: 'com.thisApp.thisApp', on itunessconnect (reserved).
Same App with a different bundle-identifier was created for Android on Google Play Console and reserved: 'com.anotherApp.anotherApp'.
None of the apps are LIVE.
Now, if I create a Flutter project I have to choose a package name say 'com.thisApp.thisApp'.
This package name will be created for both platforms by default!
Although I figured out that you could change the package name in Flutter,
as in this post - How to change package name in flutter?
However it's still isn't clear to me, if I DO change it, does the package-name must be identical foreach platform? i.e 'com.anotherApp.anotherApp' OR could the package-name/bundle-id for each platform differ? and even if it works on debug, will it work on release?
So I managed to solve this and answer my own problem.
Yes it is possible.
As already mentioned, before I started to work with Flutter, I used Android Studio and Xcode to upload a "draft version" of the App to the Google Play and App Store respectively in order to "reserve" these AppNamePackages.
Since in one store the same name/package was already taken, I used another name, for example:
com.thisApp.thisApp
and
com.anotherApp.anotherApp
To achieve this in Flutter you need to make sure that:
You change the desired applicationID in the Android-app level build.gradle file and in the AndroidManifest.xml
for this example lets call it com.thisApp.thisApp
You go through equivalent procedure for iOS by changing the desired package name in the info.plist.
for this example - com.anotherApp.anotherApp
By selecting any file under Runner folder (iOS folder in Flutter) you can click "Open iOS module in Xcode" and pick the correct App name and package in the App Project.
And that's it. Flutter didn't make problems considering the two different package names. The App bundles were uploaded based on their previous Google Play and iTunesconnet configurations.

Auto Updating Sideloaded Android App on Start

We have an Android app (.apk) published to a publicly accessible URL, any user who knows the URL can download and install the app.
The app is already installed on the relevant user phones and allowing sideload option from the settings is turned on.
How can I force the app, on start, to check for update and replace the existing app if found, then restart the app (to pick up the latest version)?
Is there a standard solution or a software package? Should I be thinking in a different way?
I am using Xamarin Forms, however, I am happy with Xamarin Android or any Java-based solution.
One thing you could do is to have a small plain text file in the same server where the APK is, that contains the version number of the APK available on the server. The runing app then just reads that text file and compares against its own version number.
If the version on the server is newer (has a higher version number), you simply download the new APK to a temp dir and install the APK programatically using the method outlined here: Android: install .apk programmatically
The way to go is HockeyApp. It´s a distribution system that does exactly what you are looking for. Besides, you get a useful crash logger and some statistics, etc. It´s free for 2 apps.
Once you install and configure their SDK in your Android app, an activity will popup telling the user a new update is available if there is any.
The user can install the new version with a button tap. Simple.
The setup process involves installing a nuget package and write a few lines of code in your main Activity class.

Eclipse: Testing more than one APK at a time

I am coding two applications at once using Eclipse.
I wanted to upload both of them to my device for testing. However, when I upload the second one, the first one gets removed..
Any tips on how I can get Eclipse to keep both of the apps on the device at the same time?
Any tips on how I can get Eclipse to keep both of the apps on the
device at the same time?
AFAIK you want to Test two different version of Sample Application in Same Device at a time.
Solution: you can not install same application with same version at a same time in any device. However what you can do is to make the Two different Version of your application and install it in your phone. for this you will just have to change the package name of each of version of app. and then you haveto install it via adb install [path/your_app.apk] Now you can test your two different version of same application at same time.
Hope it will Help you.

How to release and install two versions of the same android app using the same package on the same device

I have an android app with two different res folders (res-1, res-2) containing all layout specific and one shared package. Using ant, I can release and install on my device only one of the two versions of the app at a time. What I want is to release and install them both in the same time, in order to be able to see and test them both on my device.
Any suggestions how to achieve this ? Thanks in advance.
It's impossible to install two apps with the same package name, the existing one will be overwritten with the new installed. Rename the other package would be a solution. Maybe testing one in the AVD and the other one on the device?
Why not just include all the resources, and then at run time determine which is correct?

android development - smart way to have both the current published version and the development version on my device

I guess this could be a common problem for new android developer like myself so I thought to ask it even so it is not a big deal.
I would like to have both the current published stable version of an app and the under development version on my device. Yet when I want to install both I get
Re-installation failed due to different application signatures.
You must perform a full uninstall of the application.
I understand it technically yet I was wondering how I could have an easy way around this so I can have both application on my phone. I could change the package name for the time being but I hope there is an even more straight forward way to get it done.
Thanks
UPDATE
Solution as given by "Marc Bernstein" in the following post - thx Algo for posting the link to it
How to change package name of an Android Application
There is a way to change the package name easily in Eclipse. Right click on your project, scroll down to Android Tools, and then click on Rename Application Package.
Just change package name of your published and development version Application. Changing Package name is really very simple and easy, follow that post
https://stackoverflow.com/a/9171773/185022
The "published" version should be signed using a release keystore.
The "development" version should be signed using a debug keystore.
At installation time, Android will complain that the two applications (having the same package name) have different signatures, and won't install the latest one (Re-installation failed due to different application signatures.).
To fix this (normal) behavior, change the package name of your application while developing it (ex: com.example.myapp-dev).

Categories

Resources