Click Button On UI of App

Hi all, I am new to power shell I am trying to do automation in which I have open a application by giving path now when GUI of application appears I want to click on a button “Next” Can you help me how can i do this ? You can see attached pic for better understanding

Talha,
Welcome to the forums.

Most if not all enterprise software installers have an option to install them silently without any user interaction. You may search for the according options for your software or you may contact the vendor. I’m sure they will be happy to help you with this.
Installing software by controling GUI elements usually is unreliable and error prone.

If you cannot avoid controlling GUI elements at all you should not use PowerShell. There are tools especially made for this kind of tasks like Autohotkey or AutoIt.

1 Like

I have been worked with tools like Uipath etc but issue is that I have concluded that my task can be done only through Power Shell so is there any way I Can do this using Power Shell.

How did you come to this conclusion?

It looks like you launched the install via Start-Process. As Olaf has stated, most installers have options with one being to run silent. Have you tried “Start-Process whateverymyapp.exe /?” to get your options?

Usually you don’t need Start-Process at all. Just run the executable or the command as is and add the arguments as needed.

@Olaf @tonyd
Actually I have a task in which we have to run a automation workflow on almost 150 VM’s. All vm are on azure so that why we have power shell by default and I can run that script on all VM’s .For other RPA tools we have to install that tool on vm to run script. Therefor I am going for PowerShell can you please help me in this script writing?

Aren’t these VMs joined to an AD? Please don’t tell me you’re planning to connect to each single one of these 150 VMs via RDP session and install software manually by hand?

Again - enterprise software installers have silent installation options. If you control the GUI elements of the setup you’re doing it wrong.

If you insist to do it anyway - Autohotkey or AutoIt scripts can be compiled to executables out of the box.

PowerShell is not the right tool to control GUI elements.

Please search for the proper options to install the software you’re after … for example:
https://docs.microsoft.com/en-us/dynamicsax-2012/appuser-itpro/install-microsoft-dynamics-ax-in-silent-mode
or

@Olaf all machines are on prem and aren’t domain joined :frowning_face:, can you please suggest another option since I’ve tried UiPath but the hold back is that we need to have UiPath installed on all machines and an enterprise version.

Do you actually read my answers? I already did. More than one.

Last time I checked, Azure VM’s are not “on prem”. Can you elaborate? More of my $.02 … not managing that many systems from a domain perspective seems like a bad idea.

1 Like