Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I know how to auto start a program when Windows starts up (by creating a shortcut in the Startup folder), but when the program starts there is a button titled "Proceed" which needs to be clicked. Can this (clicking) be done by coding or software automatically?

share|improve this question
    
Can we all get the specific application? –  mdpc Feb 8 '13 at 20:29
    
Check out AutoHotkey/AutoIt. –  Karan Feb 8 '13 at 20:47
    
You could write a program to do it, if that is what you are asking. –  BenjiWiebe Feb 8 '13 at 21:10
add comment

3 Answers

I'm guessing the window you are talking about is User Account Control promting you to confirm the program that was just run by startup.

You can disable User Account Control and the prompt won't appear.

share|improve this answer
add comment

If you're interested in creating your own (AKA don't want to chance installing other people's stuff on your box), here's an example in C#:

public class PushAButton
{
        public const int WM_COMMAND = 0x111;
        public const int WM_NOTIFY = 0x004E;

        [DllImport("User32.dll")]
        public static extern int FindWindow(string strClassName, string strWindowName);
        [DllImport("User32.dll")]
        public static extern System.Int32 SendMessage(int hWnd, int Msg, int wParam, int lParam);

        [System.STAThread]
        static void Main()
        {
            /// The following code toggles the Shuffle option in Windows Media Player
            int iHandle = FindWindow("WMPlayerApp", "Windows Media Player");
            /// use spy++ to find the command. 0x499A in decimal is printed out when you press Control H in Windows Media Player.
            SendMessage(iHandle, WM_COMMAND, 0x0000499A, 0x00000000);
        }
    }

As this is just an example, you'll have to find the actual window title and executable name and the actual message number you want to send to the window with Spy++ (available with Visual Studio).

Then, simply automatically start up your button-presser program right after the other one has begun.

Links that helped me create this:

http://blogs.msdn.com/oldnewthing/archive/2006/03/02/542115.aspx

http://www.autohotkey.com/docs/misc/SendMessage.htm

http://msdn.microsoft.com/en-us/library/ms646294%28VS.85%29.aspx

http://bytes.com/topic/c-sharp/answers/813190-how-do-i-get-handle-currently-focused-window

share|improve this answer
add comment

You should use a macro recording tool. Here's a free one:

http://roomdl.com/quick-macro/

Quick Macro (QMacro) is an intelligent software to record, replay and edit keyboard and mouse macros.
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.