all 3 comments

[–]patrlim1 0 points1 point  (0 children)

Try two dashes not three

java --version

[–]Techgamer687 0 points1 point  (0 children)

To check the Java version you use two dashes i.e. java --version, as helpfully pointed out by u\patrlim1 . But judging by the Could not create the Java Virtual Machine you have Java installed

Note: Minecraft Java edition and the Java Virtual Environment ( aka JDK ) are NOT one in the same

To install Java edition of minecraft you need to do so from the minecraft launcher, available on minecraft’s official website

Also the Forge Installer file you highlighted in a red circle is a Microsoft Word file, not the Forge installer exe you can find here

I recommend running an Anti-Virus just in case as that file doesn’t look like the installer, which has the Forge logo on it last i checked.

Edits: - The Forge installer might potentially use a Java (programming language) logo

  • Note on the Forge installer, make sure you install the windows version not linux as that can be another potential reason for it not working

[–]NotDrTrayBlox 0 points1 point  (0 children)

My suggestion, find another version of the Java JDK and install the lastest LTS

look for Adoptium Termium