Exam AND-401 All QuestionsBrowse all questions from this exam
Question 32

Which of the following is a call-back method that inflates an options menu from file res/menu/menu.xml?

    Correct Answer: D

    The correct call-back method to inflate an options menu from a file like res/menu/menu.xml is onCreateOptionsMenu. This method is specifically designed to handle the creation and inflation of menu resources for an activity. It provides a Menu object where the menu items are added, typically using a MenuInflater class to inflate the XML resource into the Menu object.

Discussion
MmadiOption: D

D. onCreateOptionsMenu

MmadiOption: B

B. onCreate