This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Android and the fly likes Menu Button is not working Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Mobile » Android
Bookmark "Menu Button is not working" Watch "Menu Button is not working" New topic

Menu Button is not working

Bharath Bg

Joined: Jul 28, 2009
Posts: 1
i hav created XML for the menu layout and i am inflating the same, the code doesnt give any compilation errors but when i click on menu button menu wont appear, here is the code :

public boolean onCreateOptionMenu(Menu myMenu)


//MenuInflater inflater = getMenuInflater();
//inflater.inflate(, menu );

return true;

XML is like this

<?xml version="1.0" encoding="utf-8"?>
<menu xmlns:android=""
android:id="@+id/grour_menu" >
android:orderInCategory="0" android:visible="true" android:enabled="true" android:menuCategory="system"/>

android:orderInCategory="1" android:visible="true" android:enabled="true" android:menuCategory="system"/>

android:orderInCategory="2" android:visible="true" android:enabled="false" android:menuCategory="system"/>

android:title="My List"
android:orderInCategory="3" android:visible="true" android:enabled="false" android:menuCategory="system"/>

please help me out in solving the problem
Prajkti Khadse
Ranch Hand

Joined: Apr 02, 2009
Posts: 52
Hello Bharath,
Try this

Hope it'll work for You
I agree. Here's the link:
subject: Menu Button is not working
Similar Threads
how to add a scrollbar to a view
Layouts, bottom position
How to stop handler or thread
The application has stopped unexpectedly. Please try again.
Problems with listview and checkbox event