Which is the correct code statement to add an option in the menu in PyQt?

17. Which is the correct code statement to add an option in the menu in PyQt?

  1. menu.addNewMenu('option_name')
  2. menu.Add('option_name')
  3. menu.newMenu('option_name')
  4. menu.addMenu('option_name')

Answer: D) menu.addMenu('option_name')

Explanation:

The correct code statement to add an option in the menu in PyQt is:

menu.addMenu('option_name')

Where menu is the name of the menu bar and option_name is the new option to be added.

Comments and Discussions!

Load comments ↻






Copyright © 2024 www.includehelp.com. All rights reserved.