You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@netbeans.apache.org by Fernando Montenegro <fm...@umich.edu> on 2019/06/26 02:05:55 UTC

Cannot find symbol - org.openide.util.Utilities

Hello,

As the subject says, Netbeans is giving me that error. I am new to Netbeans and I installed NB 11 IDE running on AdoptOpenJDK 8.0.212 with OpenJ9 on Windows 10 1903.

Other classes are available, like org.openide.util.Exceptions, but not Utilities.

P.S. Similar issue with org.openide.util.HelpCtx not found

Thanks!!
Sent from my mobile


RE: Cannot find symbol - org.openide.util.Utilities

Posted by fm...@umich.edu.
Well, turns out this was rookie mistake (not surprisingly).

 

I had an older project that I was trying to open after upgrading to NB11,
but some files complained that org.openide.util.Utilities did not exist in
org.openide.util.

 

I found a bug https://netbeans.org/bugzilla/show_bug.cgi?id=252550 where
someone had a similar issue with HelpCtx. The solution was 

"You need to have the org.openide.util.ui module in your application, the
dependency on org.openide.util is not enough. For dependencies on
org.openide.util older than 9.3 the dependency on org.openide.util.ui is
automatically injected by build and by module system in runtime. For newer
you need to add the dependency yourself."

 

Which in my case translated into right-clicking on the module, and selecting
Properties. In the pop-up window I selected Libraries, and then clicked on
"Add Dependency.". I looked for the Utilities API dependency and added it.
The error disappeared and the project compiled correctly after that.

 

From: Fernando Montenegro <fm...@umich.edu> 
Sent: Tuesday, June 25, 2019 10:06 PM
To: users@netbeans.apache.org
Subject: Cannot find symbol - org.openide.util.Utilities

 

Hello,

As the subject says, Netbeans is giving me that error. I am new to Netbeans
and I installed NB 11 IDE running on AdoptOpenJDK 8.0.212 with OpenJ9 on
Windows 10 1903.

Other classes are available, like org.openide.util.Exceptions, but not
Utilities.

P.S. Similar issue with org.openide.util.HelpCtx not found

Thanks!!

Sent from my mobile