How to use java.awt namespace

It cant resolve some of the namespaces.
It works fine for java.util but for example doesnt work at all for java.awt or javax.swing
Nothing apart from Oxygene version has changed.

Surfe you haven’t updated to a new JDK version? IIRC some package names changed in a recent update, so you mighty need new/different references for java.awt.

Update: yeah, you need to reference java.desktop, for newer JDK versions.

https://docs.oracle.com/en/java/javase/16/docs/api//java.desktop/java/awt/package-use.html

(only hint to this is in the URL for the docs topic. :woman_facepalming:t3:)

Well, I’m quite sure I didn’t update I’m sitting on JDK 11 atm.
Nothings changed apart from Oxygene version.
It doesn’t see java.desktop either.
Nor java.sql, javax.swing, java.beans, javax.print.
Seems really strange

UPDATE:
Screen of settings to show you we are on JDK 11.
image
And errors.
image

Hmm, that is strange indeed. lemme grab OpenJDK 11 and compare (i have 16)

Can you send me a full “Diagnostic” level re-build log? in particular this part:

               -> Task RemObjects.EBuild.Elements.ElementsPreflightCooper started for consoleapplication20.
                  JDK found in '/Users/mh/Downloads/jdk-17.jdk/Contents/Home'.
                  Libraries found in '/Users/mh/Downloads/jdk-17.jdk/Contents/Home/jmods'.
                  Java executable found at '/Users/mh/Downloads/jdk-17.jdk/Contents/Home/bin/java'.
               <- Task RemObjects.EBuild.Elements.ElementsPreflightCooper finished for consoleapplication20, 

and let me know whats in then folder mentioned under “Libraries found in”?

Mine has

java.base.jmod
java.compiler.jmod
java.datatransfer.jmod
java.desktop.jmod
java.instrument.jmod
java.logging.jmod
java.management.jmod
java.management.rmi.jmod
java.naming.jmod
java.net.http.jmod
java.prefs.jmod
java.rmi.jmod
java.scripting.jmod
java.se.jmod
java.security.jgss.jmod
java.security.sasl.jmod
java.smartcardio.jmod
java.sql.jmod
java.sql.rowset.jmod
java.transaction.xa.jmod
java.xml.crypto.jmod
java.xml.jmod
jdk.accessibility.jmod
jdk.attach.jmod
jdk.charsets.jmod
jdk.compiler.jmod
jdk.crypto.cryptoki.jmod
jdk.crypto.ec.jmod
jdk.dynalink.jmod
jdk.editpad.jmod
jdk.hotspot.agent.jmod
jdk.httpserver.jmod
jdk.incubator.foreign.jmod
jdk.incubator.vector.jmod
jdk.internal.ed.jmod
jdk.internal.jvmstat.jmod
jdk.internal.le.jmod
jdk.internal.opt.jmod
jdk.internal.vm.ci.jmod
jdk.internal.vm.compiler.jmod
jdk.internal.vm.compiler.management.jmod
jdk.jartool.jmod
jdk.javadoc.jmod
jdk.jcmd.jmod
jdk.jconsole.jmod
jdk.jdeps.jmod
jdk.jdi.jmod
jdk.jdwp.agent.jmod
jdk.jfr.jmod
jdk.jlink.jmod
jdk.jpackage.jmod
jdk.jshell.jmod
jdk.jsobject.jmod
jdk.jstatd.jmod
jdk.localedata.jmod
jdk.management.agent.jmod
jdk.management.jfr.jmod
jdk.management.jmod
jdk.naming.dns.jmod
jdk.naming.rmi.jmod
jdk.net.jmod
jdk.nio.mapmode.jmod
jdk.random.jmod
jdk.sctp.jmod
jdk.security.auth.jmod
jdk.security.jgss.jmod
jdk.unsupported.desktop.jmod
jdk.unsupported.jmod
jdk.xml.dom.jmod
jdk.zipfs.jmod

Looks like OpenJDK 11 is no longer available for download for Mac, but in the Windows zip, the jmods folder looks the same, and java.desktop.jmod is there…

Well then it shouldn’t work before upgrading to the preview version but it did. To be sure ill install stable and check.
Update:
Ok, so I added manually java.desktop and it started to see some references, although it wasn’t needed before while using Oxygene.
Are you sure you didn’t change anything connected with linking JDK?

To be clear nothing changed here for Oxygene in months, if not years. And yes, JDK11 would also require the java.desktop reference, this is not a new change (again, in the JDK, not Oxygene).

Maybe something else upgraded your JDK, unbeknownst to you?

2000% sure. Nothing changed here in forever.

This was a change in JDK, not in Oxygene. All that changed in Oxygfene (years ago) was to ass support for the new SDK structure (smaller .jmods, and java.base.jmod as main reference, when using newer JDKs, etc, instead of the classic 'rt.jar` that have everything) — and without that (eg if you were upgrading from a very old Oxygene that didn’t have this yet), building against JDK11 would just not have worked at all.

My money is on your JDK getting updated ifor some reason.