Sign in to follow this  
Followers 0

WinMenuSelectItem and ControlCommand(SelectString)

2 posts in this topic

#1 ·  Posted (edited)

My code is:

If WinExists("User Agreement & Disclaimer") And ControlCommand("User Agreement & Disclaimer", "", "", "IsEnabled", "") = 1 Then
        ControlClick("User Agreement & Disclaimer", "", "")
        WinWait("Guitar Hero Three Control Panel")
        WinMenuSelectItem("Guitar Hero Three Control Panel", "", "File", "&Open Game Settings")
        WinWait("Choose which game settings to load")
        ControlCommand("Choose which game settings to load", "", "", "SelectString", "Guitar Hero III (English)")
        ControlClick("Choose which game settings to load", "", "")

But it doesn't work and I have no idea why, can anyone help? (nothing works after the first WinWait command, before you say that I may put wrong title, I've put a MsgBox command after WinWait and it shown up, so it means something is wrong in the commands after the first WinWait)

EDIT: Also this doesn't work either:

If WinExists("ExecuteActions") And ControlCommand("ExecuteActions", "", "", "IsEnabled", "") = 1 Then
        ControlClick("ExecuteActions", "", "")
        ;If TrayItemGetState($launchgame) = 1 Then Run("C:\Program Files\Aspyr\Guitar Hero III\GH3.exe")
        If TrayItemGetState($launchgame) = $TRAY_CHECKED Then MsgBox(0, "", "")

Everything (in this code) works except the last line, it doesn't recognize if the tray item is checked or not. Nothing happened when I use $TRAY_CHECKED or 1.

Edited by Asd123456

Share this post

Link to post
Share on other sites


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  
Followers 0