title: Automate Microsoft SDK for Java 4.0 installer
body: <p>I am trying to install Microsoft SDK for Java 4.0 for one of my legacy projects using AutoIt.</p>
  
  <p><a href="https://i.stack.imgur.com/LYohs.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/LYohs.png" alt="enter image description here"></a></p>
  
  <p>On the first setup window there is a small where I need to activate that screen and select enter. But it is not happening. Below is the code I am using:</p>
  
  <pre><code>Run("SDKJava40.exe")
  Sleep(500)
  
  WinWait("Microsoft SDK for Java 4.0 Setup", "Welcome to the")
  WinActivate("Microsoft SDK for Java 4.0", "Welcome to the")
  Sleep(1000)
  Send("{ENTER}")
  
  WinWait("Software License Agreement", "Please read the following")
  WinActivate("Software License Agreement", "Please read the following")
  Sleep(1000)
  Send("{ENTER}")
  </code></pre>