Android - No Launcher activity found - android

When I launch my app with Eclipse, I get this error :
No Launcher activity found!
launch will only sync the application package on the device!
However, the AndroidManifest seems correct :
<application
android:name="com.myapp.MyApplication"
android:allowBackup="true"
android:largeHeap="true"
android:icon="#drawable/icon"
android:label="#string/name"
android:theme="#style/myTheme" >
<activity
android:name="com.myapp.OpeningActivity"
android:theme="#android:style/Theme.Holo.NoActionBar"
android:label="#string/name">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
<action android:name="android.hardware.usb.action.USB_DEVICE_ATTACHED" />
</intent-filter>
<meta-data android:name="android.hardware.usb.action.USB_DEVICE_ATTACHED"
android:resource="#xml/myxml" />
</activity>
<receiver android:name="com.myapp.MyBootReceiver" >
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED" />
<action android:name="android.intent.action.QUICKBOOT_POWERON" />
<action android:name="com.parrot.intent.action.LAUNCH_NAP_APP" />
</intent-filter>
</receiver>
</application>
I can't see anything worst in this code.
Note that with AndroidStudio, this error not appears. So... is Eclipse the problem ?
Thank you for your help.

Related

Android assistant - MediaBrowserService - Voice command - "Play x on appName"

The voice commande Play [song] on [my appName] command not working, the "appName" is not being recognised by google assistante.
I followed the instruction form https://developer.android.com/guide/topics/media-apps/interacting-with-assistant and the demo app form https://github.com/android/uamp
My AndroidManifest:
<application
android:name=".XApplication"
android:allowBackup="false"
android:icon="#mipmap/ic_launcher"
android:label="#string/app_name" // app_name = appX 101.1
android:roundIcon="#mipmap/ic_launcher_round"
android:supportsRtl="false"
android:theme="#style/AppTheme">
<activity
android:name=".ui.splash.SplashActivity"
android:exported="true"
android:launchMode="singleTop"
android:screenOrientation="portrait"
android:theme="#style/AppTheme.AppFullScreenTheme"
android:windowSoftInputMode="adjustPan|stateHidden">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<intent-filter>
<action android:name="android.media.action.MEDIA_PLAY_FROM_SEARCH" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
...
...
<service
android:name="com.music.android.xx.media.MusicService"
android:enabled="true"
android:exported="true"
tools:ignore="ExportedService">
<intent-filter>
<action android:name="android.media.browse.MediaBrowserService" />
</intent-filter>
</service>
<service
android:name=".service.LocationUpdatesService"
android:foregroundServiceType="location" />
<receiver android:name=".service.StopServiceReceiver" />
<receiver android:name=".service.PlayRadioReceiver" />
<service
android:name=".service.MyFirebaseService"
android:exported="false">
<intent-filter>
<action android:name="com.google.firebase.MESSAGING_EVENT" />
</intent-filter>
</service>
I have a problem figuring out what I did wrong or what I missed . Any help will be greatly appreciated..
PS: My app had been in the store for 4days and my App Name have numbers in it like "appX 101.1" (i'm worried that this may be an issue)

My application icon doesn't appear when I debug or Run 'app' on android studio, what happened?

My application icon no longer appears on my android phone screen when I debug like it used to. I know this has something to do with the androidmanifest.xml file. I've looked up several solutions for me but those solutions resulted in my application being unable to even run in the first place.
What could be the problem here?
I have tried the solutions mentioned here:
Android Studio: App icon doesn't appear in the home screen or app list
Launcher icon missing in Android
This is my android manifest file:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="sg.edu.singaporetech.teamproject">
<uses-permission android:name="android.permission.INTERNET" /> <!-- allow usage of camera for Android -->
<uses-permission android:name="android.permission.FOREGROUND_SERVICE"/> <!-- to run foreground service for steps -->
<uses-feature
android:name="android.hardware.camera"
android:required="true" />
<application
android:name=".StepsNotification"
android:allowBackup="true"
android:icon="#drawable/exersize"
android:label="#string/app_name"
android:roundIcon="#mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="#style/Theme.AppCompat.Light.NoActionBar">
<activity android:name=".DispatchActivity">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.VIEW" />
</intent-filter>
</activity>
<activity android:name=".profile.editProfile"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".MainActivity"
android:label="#string/app_name"
android:theme="#style/AppTheme.NoActionBar"
android:screenOrientation="portrait"
android:configChanges="orientation|keyboardHidden">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".registration.RegisterActivity">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".home.HomeActivity">
<!--<intent-filter>-->
<!--<action android:name="android.intent.action.MAIN" />-->
<!--<category android:name="android.intent.category.LAUNCHER" />-->
<!--</intent-filter>-->
</activity>
<receiver android:name=".StepsBroadcastReceiver">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED"/>
<action android:name="android.net.conn.CONNECTIVITY_CHANGE"/>
</intent-filter>
</receiver>
<service android:name=".StepsService"/>
</application>
</manifest>
I think the problem is in the line,
android:icon="#drawable/exersize"
In the application tag, app icon must he placed in the mipmap folder as it meant for the app icon only. Mipmap must have all scales of the icon.

Android - Launcher Application breaks after reboot phone

Here is my manifest:
<application
android:allowBackup="true"
android:icon="#drawable/toto"
android:label="#string/app_name"
android:theme="#style/AppTheme"
android:process=":app_process">
<activity
android:name=".core.Main"
android:label="app_label"
android:launchMode="singleTask"
android:alwaysRetainTaskState="true">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<action android:name="android.nfc.action.TECH_DISCOVERED" />
<category android:name="android.intent.category.LAUNCHER" />
<category android:name="android.intent.category.HOME" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
<meta-data
android:name="android.nfc.action.TECH_DISCOVERED"
android:resource="#xml/nfc_tech_filter" />
</activity>
<service android:name=".core.MessengerService"
android:enabled="true"
android:process=":app_process">
<intent-filter>
<action android:name="My_Messenger_Service"/>
</intent-filter>
</service>
<receiver
android:name=".core.BootReceiver"
android:enabled="true"
android:label="StartMyServiceAtBootReceiver">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED" />
</intent-filter>
</receiver>
</application>
My launcher breaks after reboot phone, then the phone asks me to choose the default launcher which contains Android default launcher and my launcher.
I tried to get logcat by using command line:
adb logcat -d > logcat.txt
But I didn't find any error log E/ of my launcher. How can I trace this error?
Can someone helps me pls? Thanks,
I added this param and it worked
android:clearTaskOnLaunch="true"

Eclipse showing No launcher Activity found

This is my android Manifest.xml.
<?xml version="1.0" encoding="utf-8"?>
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
package="uk.co.halfninja.wallpaper.parallax">
<uses-sdk android:minSdkVersion="7" />
<uses-feature android:name="android.software.live_wallpaper" />
<application
android:label="#string/app_name"
android:icon="#drawable/icon">
<service
android:label="#string/app_name"
android:name=".ParallaxWallpaper"
android:permission="android.permission.BIND_WALLPAPER">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<meta-data android:name="android.service.wallpaper" android:resource="#xml/wallpaper" />
</service>
<activity
android:label="#string/wallpaper_settings"
android:name=".ParallaxWallpaperSettings"
android:theme="#android:style/Theme.Black.NoTitleBar"
android:exported="true">
</activity>
</application>
</manifest>
Still Eclipse showing the result
ParallaxWallpaper] No Launcher activity found!
ParallaxWallpaper] The launch will only sync the application package on the device!
ParallaxWallpaper] Performing sync
ParallaxWallpaper] Automatic Target Mode: Unable to detect device compatibility. Please select a target device.
Please let me Know where am i doing the mistake, and what would be the solution...???
Move the intent-filter tag from service to activity
These lines should be in Activity tag
<application
android:label="#string/app_name"
android:icon="#drawable/icon">
<activity
android:label="#string/wallpaper_settings"
android:name=".ParallaxWallpaperSettings"
android:theme="#android:style/Theme.Black.NoTitleBar" android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<service
android:label="#string/app_name"
android:name=".ParallaxWallpaper"
android:permission="android.permission.BIND_WALLPAPER">
</service>
<meta-data android:name="android.service.wallpaper" android:resource="#xml/wallpaper" />
</application>
make activity as launcher you have made service as launcher. like that
<activity
android:label="#string/wallpaper_settings"
android:name=".ParallaxWallpaperSettings"
android:theme="#android:style/Theme.Black.NoTitleBar"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>

App isnt installed widget android

Trying to test a widget.The Widget appear in the widget tab when I click on it, I get app is not installed toast message in Emulator
I don't really understand how widget works , so one more sub-question : I followed http://kasperholtze.com/android/how-to-make-a-simple-android-widget/ tutorial -> now I have this source code , perhaps I need to run it even once from an activity , how the code is compiled into the widget anyway?
Below is the manifest.
<receiver
android:name=".TimeWidget"
android:label="Time" >
<intent-filter>
<action android:name="android.intent.action.AIRPLANE_MODE"/>
<action android:name="android.appwidget.action.APPWIDGET_UPDATE" />
</intent-filter>
<meta-data
android:name="android.appwidget.provider"
android:resource="#xml/time_widget_provider" />
</receiver>
<activity
android:name="com.example.ass3.MainActivity"
android:label="#string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name=".ConfigurationActivity" >
<intent-filter>
<action android:name="android.appwidget.action.APPWIDGET_CONFIGURE" />
</intent-filter>
</activity>
<activity android:name="IncCallHistory" android:label="Incoming Call History"></activity>
<activity android:name="TimeWidget" android:label="Time Widget"></activity>
</application>

Categories

Resources