Jump to content
Sign in to follow this  
Penisaurus

Menu Item From A Menu Item

Recommended Posts

Penisaurus

Can a menu item from a menu item be possible?

For example, a browser will the Menu 'File' > 'Options' > 'Options Here'

I thought you could do it like this, but it did not work:

#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>

$Form1 = GUICreate("Form1", 505, 302, 192, 124)
$Menu = GUICtrlCreateMenu("File")
$Options = GUICtrlCreateMenuItem("Options", $Menu)
$Option1 = GUICtrlCreateMenuItem("Option1", $Options)
GUISetState(@SW_SHOW)



While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

    EndSwitch
WEnd

Is there a way to do this?

Share this post


Link to post
Share on other sites
Yoriz

#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>

$Form1 = GUICreate("Form1", 505, 302, 192, 124)
$Menu = GUICtrlCreateMenu("File")
$Options = GUICtrlCreateMenu("Options", $Menu,1)
$Option1 = GUICtrlCreateMenuItem("Option1", $Options)
GUISetState(@SW_SHOW)



While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

    EndSwitch
WEnd


GDIPlusDispose - A modified version of GDIPlus that auto disposes of its own objects before shutdown of the Dll using the same function Syntax as the original.EzMySql UDF - Use MySql Databases with autoit with syntax similar to SQLite UDF.

Share this post


Link to post
Share on other sites
Penisaurus

#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>

$Form1 = GUICreate("Form1", 505, 302, 192, 124)
$Menu = GUICtrlCreateMenu("File")
$Options = GUICtrlCreateMenu("Options", $Menu,1)
$Option1 = GUICtrlCreateMenuItem("Option1", $Options)
GUISetState(@SW_SHOW)



While 1
    $nMsg = GUIGetMsg()
    Switch $nMsg
        Case $GUI_EVENT_CLOSE
            Exit

    EndSwitch
WEnd

Thank you. That's exactly what I was looking for.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.