As far as i know you can use every Java version when you are just in the right directory. Lets say i have on my PC Java 8 and Java 15. They are both located in C:Program Filesjava. So when i go in C:Program Filesjavajre1.8.0_291bin and run in cmd java.exe -version i get the version 1.8 . The same goes
Tag: powershell
How to turn off monitor power programmatically in windows 10 if power button is broken
The power button on my second monitor is broken. I’m tired of manually unplugging the cable from the monitor. What do I want is to write a small app (Java, C#, or PowerShell script) that will turn the …
I was able to compile my java code from PowerShell, but cannot run it
I was able to compile and run my java code from CMD, however when I try to run the same commands in PS, I am getting error messages. I have read and been told that CMD commands will work in PS, but …
Powershell install Java silently
I need to install new Java update silently. I have these arguments for installation: and I tried: and also: and both version has prompt dialog. How to install it silently? Answer I found solution in cmdLet Execute-Process via this script. Works fine! And calling it: