3

I am trying to automate typing Win + R, and entering mstsc. This should open a Remote Desktop Protocol (RDP) window. In the RDP window, I have to enter a host name. All these should be done using UI path.

How can I achieve this?

3

You have the option to connect using a set of commands

But if you want to use the UI for this or other Windows related apps, you can try pywinauto. Here is an example from the pywinauto docs:

from pywinauto.application import Application
# Run a target application
app = Application().start("notepad.exe")
# Select a menu item
app.UntitledNotepad.menu_select("Help->About Notepad")
# Click on a button
app.AboutNotepad.OK.click()
# Type a text string
app.UntitledNotepad.Edit.type_keys("pywinauto Works!", with_spaces = True)
  • 1
    I think the main issue here is how to access controls within RDP screen. – Alexey R. Dec 21 '18 at 11:44
  • @AlexeyR. yes. I am trying to use explore how to use UI path to automate a particular scenario which requires me to take a remote desktop connection. – shruthi Dec 22 '18 at 14:03
  • Remote Execution Guide – Vasily Ryabov Dec 25 '18 at 12:43

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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