title: How to Click "Yes" button in order application with code
body: <p>I have a code </p>
  
  <pre><code> private const int WM_CLOSE = 16;
      private const int BN_CLICKED = 245;
      [DllImport("User32.dll")]
      public static extern Int32 FindWindow(String lpClassName, String lpWindowName);
  
      [DllImport("user32.dll", CharSet = CharSet.Auto)]
      public static extern int SendMessage(int hWnd, int msg, int wParam, IntPtr lParam);
  
      [DllImport("user32.dll", SetLastError = true)]
      public static extern IntPtr FindWindowEx(IntPtr parentHandle, IntPtr childAfter, string className, string windowTitle);
  
      [DllImport("user32.dll", EntryPoint = "FindWindow", SetLastError = true)]
      private static extern IntPtr FindWindowByCaption(IntPtr ZeroOnly, string lpWindowName);
  
  
  
   public void Click(string _btnTitle)
      {
          int hwnd = 0;
          IntPtr hwndChild = IntPtr.Zero;
  
          //Get a handle for the Calculator Application main window
          // foreach (Process p in Process.GetProcesses())
          //{   
          hwnd = FindWindow(null, FrmTitle);            
          if (hwnd != 0)
          {
              hwndChild = FindWindowEx((IntPtr)hwnd, IntPtr.Zero, "Button", _btnTitle);
              SendMessage((int)hwndChild, BN_CLICKED, 0, IntPtr.Zero);
          }
      }
  </code></pre>
  
  <p>I can't Click button "Yes" on MessageBox of application :(</p>
  
  <p>Anyone got a tip? Tks</p>