Netbeans gives a warning to not try and change the code it generates and
says that it will change it back the next time I run or build the file.
Someone did suggest loading my project into github. I have heard of
github but have no idea of how to use it or load stuff into it. I guess
this mailing group won't allow attachments?
Judi
On 10/03/2020 12:53, Geertjan Wielenga wrote:
We’d love to help you and, yes, you can indeed change code that
NetBeans generates.
Can you help us to help you — put your code somewhere so that we can
look at it?
Gj
On Tue, 10 Mar 2020 at 13:48, Judi Rastall <j...@rastall.com
<mailto:j...@rastall.com>> wrote:
I have been doing some digging around and the first line where an
image is called is the line identified as giving the error.
However, this is part of the code generated by Netbeans when I
created the panel using the design feature in Netbeans. In other
words, I cannot alter it! Netbeans knows best!
I thought that using the built-in design tools would be quicker
and easier but that approach has been my undoing. So yes, I do
blame Netbeans for my difficulties.
I have made a start on rewriting everything from scratch. This is
not helped by the many different ways in which different folk
suggest the calls should be done. Neil's suggestion of Googling
loading icons was helpful but did throw up several discussion
threads where others were having similar difficulties. It seems
that every tutorial I have found gives a different construction.
The only thing that is keeping me going on trying to learn Java at
all is the goal of "write & compile once, run anywhere".
Judi
On 09/03/2020 18:14, Neil C Smith wrote:
On Mon, 9 Mar 2020 at 17:58, Judi Rastall<j...@rastall.com>
<mailto:j...@rastall.com> wrote:
Trying to run from the CMD prompt, I see this error message:
Exception in thread "main" java.lang.NullPointerException
at javax.swing.ImageIcon.<init>(Unknown Source)
...
Why will a program that runs perfectly well within the IDE fail to run when
compiles?
Quite easily! My guess is the way you're passing the icon location
into ImageIcon. You may want to Google on loading icons bundling in
JARs - you'll find lots of info. Loading resources from inside a JAR
is (can be) different to loading from the filesystem.
Best wishes,
Neil
---------------------------------------------------------------------
To unsubscribe, e-mail:users-unsubscr...@netbeans.apache.org
<mailto:users-unsubscr...@netbeans.apache.org>
For additional commands, e-mail:users-h...@netbeans.apache.org
<mailto:users-h...@netbeans.apache.org>
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists