Looks like you need to have .NET framework 3.5 installed on your machine to run your program. When you install Visual Studio, it gets installed automatically and it looks to me that you are uninstalling .NET Framework 3.5 as well when you uninstall Visual Studio.
So, on a fresh machine, install .NET Framework 3.5 and then try to run the program and see how it goes. You can download it
here.[
^]