Well, i used App Compact Actionbar with ActionBarActivity. when app crash, app will restart again and i got duplicate menu item on App Home Screen . i don't know why its crash. Can anybody please answer my. i hope i'll get the result.
Here is Optionmenu XML.
<menu xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
tools:context="com.demo.MainActivity" >
<item
android:id="@+id/action_cart"
android:icon="@drawable/action_cart_hover"
android:title="@string/action_cart"
app:actionLayout="@layout/item_actionbar_cart_count"
app:showAsAction="always"/>
Thanks in advance.
I dont know what happened when your apps crashing (a
logcat
will be helpful), but try to callclear
method :