Do you know that even the installation of software in your computer can be automated as well? In this tutorial, it will show you how to install three different software programs - WinRAR, Notepad++, and Apache OpenOffice - through an automated script. 

To start, you have to download the installers for these software programs which can be downloaded here, here, and here

After downloading the installers, create a sample Excel Worksheet and save it as "Basic Installers List". In Column A, write the names of the three software programs and then in Column B, write the file paths of the installers. Also, rename the Worksheet from "Sheet1" to "Basic Installers". A screenshot of the sample Spreadsheet is provided below.


Important Note:
Please make sure that the path of the installers on the spreadsheet are the correct path where you stored them.

Do not just copy the file path seen on the screenshots provided.

Now, follow these steps to install the three software programs using RAX EDITOR:


Part I. Getting the Software Programs' Names from Excel 


Step 1. Open RAX EDITOR and create a new workflow


Step 2. Add a Write Line activity that says "Software installations sequence has started.".



Step 3. Drag an Excel Sequence activity and drop it inside the Main Sequence




Step 4. In the File Path input field, paste the directory path of the Spreadsheet you created earlier and enclose it with quotation marks ("").




Step 5. Create an IEnumerable<Object> variable called softwareInstallersList.

a. You could do so by declaring the variable name, softwareInstallersList, then for the Variable Type, click on Browse for Types


b. Type ienumerable on the Type Name input box:


c. Click on IEnumerable<T> under System.Collections.Generic:


d. Choose Object from the dropdown list beside the System.Collections.Generic.IEnumerable text


Step 6. Drag a Read Column activity and drop it inside the Excel Sequence.



Step 7. In the Worksheet input field, type the name of your worksheet which is "Basic Installers".

Step 8. In the Column input field, type "A" since what we want to get from the Worksheet are the names of the software programs.



Step 9. Look for Values in Read Column's attributes and then set its value to softwareInstallersList. The names retrieved by this activity will be stored in this variable.



By the end of this part, your workflow should now look like this:



Part II. While Loop - Installing the Software


Step 1. Create an Int32 variable called counter and then set its Default value to 1.


Step 2. Drag a While activity and drop it inside the Excel Sequence.




Step 3. In the Condition input field, write counter < softwareInstallersList.Count(). This means as long as the value of counter is less than the number of software programs, the loop will continue to execute.



Step 4. Drag a Sequence activity and drop it inside the Body of While activity.



Step 5. Drag a Switch activity and choose String as the Variable Type then drop it inside the Sequence.



Step 6. In the Expression input field, type softwareInstallersList(counter).ToString(). This expression will run through each software program from the Spreadsheet document.



Step 7. Drag an Assign activity and drop it inside the Sequence.



Step 8. Assign counter + 1 to the counter variable.




Once done, let us move on to the third part.



Part III. Case WinRAR - Installing WinRAR


Step 1. Back to the Switch<String> activity, click Add new case and name the Case value as WinRAR.



Step 2. Drag a Sequence activity and drop it inside the WinRAR case.



Step 3. Add a Write Line activity that says "WinRAR installation has started".




Step 4. Create a String variable called softwareFileNameString.


Step 5. Drag a Read Cell activity and drop it inside the WinRAR case


.


Step 6. In the Worksheet input field, type "Basic Installers".

Step 7. In the Column input field, write "B" since the value that we will retrieve is from this column.

Step 8. In the Row input field, write (counter+1).ToString().



Step 9. Look for Value in Read Cell's attributes and set its value to softwareFileNameString. The directory path of WinRAR's installer will be stored in this variable.



Step 10. Drag a Command Prompt activity and drop it inside the WinRAR case.



Step 11. In the Command Prompt input field, type softwareFileNameString.




Step 12. Add Mouse activities inside the Sequence that will click through the installation process of WinRAR. 

You would have to manually execute the Win RAR installer then use the Mouse Activity's Select Element on Screen button to identify all buttons that RAX would need to click in order to finish the installation.


Step 13. Add a Write Line activity below the Mouse activities that says "WinRAR installation has been completed".




Part IV. Case Notepad++ - Installing Notepad++


Step 1. Click Add new case and name the Case value as Notepad++.


Step 2. Drag a Sequence activity and drop it inside the Notepad++ case.



Step 3. Add a Write Line activity that says "Notepad++ installation has started".



Step 4. Drag a Read Cell activity and drop it inside the Notepad++ case.



Step 5. In the Worksheet input field, type "Basic Installers".

Step 6. In the Column input field, write "B" since the value that we will retrieve is from this column.

Step 7. In the Row input field, write (counter+1).ToString().



Step 8. Look for Value in Read Cell's attributes and set its value to softwareFileNameString. The directory path of Notepad++'s installer will be stored in this variable.



Step 9. Drag a Command Prompt activity and drop it inside the Notepadd++ case.




Step 10. In the Command Prompt input field, type softwareFileNameString.




Step 11. Add Mouse activities inside the Sequence that will click through the installation process of Notepad++.

You would have to manually execute the Notepad++ installer then use the Mouse Activity's Select Element on Screen button to identify all buttons that RAX would need to click in order to finish the installation.

Step 12. Directly after the Mouse activities, add a Write Line activity that says "Notepad++ installation has been completed".




Part V. Case Apache OpenOffice - Installing Apache OpenOffice


Step 1. Click Add new case and name the Case value as Apache OpenOffice.



Step 2. Drag a Sequence activity and drop it inside the Apache OpenOffice case.



Step 3. Add a Write Line activity that says "Apache OpenOffice installation has started.".




Step 4. Drag a Read Cell activity and drop it inside the Apache OpenOffice case.




Step 5. In the Worksheet input field, type "Basic Installers".

Step 6. In the Column input field, write "B" since the value that we will retrieve is from this column.

Step 7. In the Row input field, write (counter+1).ToString().




Step 8. Look for Value in Read Cell's attributes and set its value to softwareFileNameString. The directory path of Apache OpenOffice's installer will be stored in this variable.



Step 9. Drag a Command Prompt activity and drop it inside the Apache OpenOffice case.



Step 10. In the Command input field, type softwareFileNameString.



Step 11. Add Mouse activities inside the Sequence that will click through the installation process of Apache OpenOffice.

You would have to manually execute the Apache OpenOffice installer then use the Mouse Activity's Select Element on Screen button to identify all buttons that RAX would need to click in order to finish the installation.

Step 12. Directly after the Mouse activities, add a Write Line activity that says "Apache OpenOffice installation has been completed".



Part VI. Restart PC Sequence


Step 1. Drag a Sequence activity inside the Main Sequence, after the Excel Sequence.




Step 2. Add a Write Line activity that says "Software installations sequence complete. Restarting PC...".



Step 3. Drag a Command Prompt activity inside the Sequence.



Step 4. In the Command input field, write "shutdown /r /t 0". This command will restart your PC.



And you're done! Upon execution of this workflow, these three software programs will be automatically installed in your PC one by one. After the installations, the PC will restart.