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

  • SEARCH
  • Home
  • 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 7061345
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T04:27:45+00:00 2026-05-28T04:27:45+00:00

I have developed an android app that mainly targets smartphones. However in tablet emulator

  • 0

I have developed an android app that mainly targets smartphones. However in tablet emulator I see that it works on android 3.x, too.

However there is one little problem. The user cannot open OptionsMenu when he clicks on the menu button. As you know on the smartphone a menu appears from the bottom. But on tablet nothing happens.

I have read this http://developer.android.com/guide/topics/ui/menus.html#options-menu but still cannot figure out how to manage this. My app has a custom action bar.

My code is quite straight forward. In main activity:

@Override
public boolean onCreateOptionsMenu(Menu men) {
    MenuInflater inflater = getMenuInflater();
    inflater.inflate(R.layout.menu, men);
    return true;
}

@Override
public boolean onOptionsItemSelected(MenuItem item) {
    // Handle item selection
    switch (item.getItemId()) {
    //...
    }
}

And the prefs activity:

public class MdPrefsActivity extends PreferenceActivity {
     @Override
     protected void onCreate(Bundle savedInstanceState) {
         super.onCreate(savedInstanceState);

         getPreferenceManager().setSharedPreferencesName(
                 MdSharedPrefs.PREFS_NAME);
         addPreferencesFromResource(R.xml.prefs);
     }
}

MdSharedPrefs class just contains some getters and setters to retrieve/write the pref values.

Any ideas how I can show the OptionsMenu on tablet?

  • 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-05-28T04:27:46+00:00Added an answer on May 28, 2026 at 4:27 am

    As the documentation said:

    Items in the Options Menu are accessible in two distinct ways: the
    MENU button or in the Action Bar (on devices running Android 3.0 or
    higher).

    […]

    On Android 3.0 and higher, items from the Options Menu is placed in
    the Action Bar, which appears at the top of the activity in place of
    the traditional title bar. By default all items from the Options Menu
    are placed in the overflow menu, which the user can open by touching
    the menu icon on the right side of the Action Bar. However, you can
    place select menu items directly in the Action Bar as “action items,”
    for instant access […]

    So for Android 3.0 or higher you can see only the menu items in the ActionBar.

    It is also important to notice that:

    Beginning with Android 3.0 (API level 11), the action bar is included
    in all activities that use the Theme.Holo theme (or one of its
    descendants), which is the default theme when either the
    targetSdkVersion or minSdkVersion attribute is set to “11” or greater.

    But be aware that the ActionBar is visible only if you don’t have an application or activity theme that explicitly hides it like

    android:theme="@android:style/Theme.Holo.NoActionBar"
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have developed an android app that works great and i would like to
I have developed an App that target version is 4 (Android 1.6) upto 7
I have developed a business app that runs fine on android phone. What do
Right now, I have developed an android app that is available free on the
I have developed an Android App that contains a list of information. I want
I have developed an android app that automatically sends an SMS automatically to a
I have a mobile app that I developed using PhoneGap (and html/css/javascript) and there
http://developer.android.com/tools/publishing/app-signing.html I have a keystore that I already have an alias and password for.
I have an app that I want to develop for Android 2.1, 2.2, 2.3.3,
I have to develop an App for Android tablets that demands printing files to

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.