When setting up Netbeans 12.2, one part of the installer lets you select the JavaSDK that you'll use as the Default. Is there any way to change this later on, like when a new version of the JavaSDK comes out?
It is possible to change the platform later.
You need to distinguish between two platforms:
If you want to change the Java version for the IDE, check the configuration file in the netbeans/etc folder (on my windows machine it is C:\Program Files\NetBeans-12.2\netbeans\etc\netbeans.conf
. In line 76 I see the variable netbeans_jdkhome
.
If you installed another JDK on your machine and want to choose that for projects, inside Netbeans go to Tools/Java Platforms. Add your new installation. Then when you go to some project's properties, look at the Build/compile settings. Choose your new java platform, and it will be used for your project.