title: How to read text from an application window using pywinauto
body: <p>I have a python code which opens a SSH session using Putty and passes a command to reboot a remote machine using pywinauto.
  I want to read the text from the putty terminal after typing the password and compare it
  Is there a way I can do it?
  Below is the piece of code for the same</p>
  
  <pre><code>    app_Putty = application.Application()
      app_Putty.start_("C:\Users\debajyoti.bose\Downloads\putty.exe")
      app_Putty.top_window_().TypeKeys(IP)
      app_Putty.top_window_().TypeKeys("{TAB}"+"22")
      app_Putty.top_window_().RadioButton4.Click()
      app_Putty.top_window_().OpenButton.Click()
      time.sleep(10)
      app_Putty.top_window_().NoButton.Click()
      time.sleep(2)
      app_Putty.top_window_().TypeKeys(user+"{ENTER}")
      time.sleep(3)
      app_Putty.top_window_().TypeKeys(password+"{ENTER}")
      time.sleep(3)
      app_Putty.top_window_().TypeKeys("/bin/reboot"+"{ENTER}")
      time.sleep(5)
      app_Putty.kill_()
      time.sleep(120)
  </code></pre>
  
  <p>I am using pywinauto v0.4.0
  Thanks in advance.</p>