Cynthia Jeness wrote:
> 
> Tram,
> 
> I see similar results and believe that this was a "bug?" introduced in the
> second early access release.  In order to work around it, I put all of my help
> initilialization in the "run" method of its own class.  Then I use
> "SwingUtilities.invokeLater()" on this class.  This works for me, but I am not
> sure that it should be necessary.
> 
> Cynthia Jeness
> 
> Nguyen, Tram N. wrote:
> 
> > I know this is not exactly where i should post this question , but it seems
> > like this is where I learned a lot of things concerning Java topics
> > (although I haven't use my Linux box for a while), I hope you-experienced
> > java programmers- might help me out with this.
> >
> > I'm trying to implement a Help System system using JavaHelp EA provided by
> > Sun.I have jdk1.1.6 installed on my PC . I try to write very simple script
> > followed code fragment and demos from Sun docs; however, i keep getting
> > NullPointerException when trying to set a HelpSet from URL . I'm pretty
> > sure
> > that the way I setup my help docs is correct since I can use hsviewer to
> > bring up this helpset file and its sub files . Here some of my code and
> > where it gets choked.
> >
> > public class iscsbJPanel extends com.sun.java.swing.JPanel implements
> > java.awt.event.ActionListener
> > {
> >     HelpSet mainHS;
> >     HelpBroker mainHB;
> >     static final String helpsetName = "tram";
> >
> >  public iscsbJPanel()
> >  {
> >   super();
> >   try {
> >             ClassLoader cl = iscsbJPanel.class.getClassLoader();
> >             URL url = HelpSet.findHelpSet(cl, helpsetName);
> >             System.out.println("URL : " + url.toString());
> >             mainHS = new HelpSet(cl,url);
> >         } catch (Exception ee) {
> >             System.out.println ("Help Set "+helpsetName+" not found : "
> > + ee.toString());
> >             ee.printStackTrace();
> >             return;
> >         }
> >  }
> >
> > Output :
> > URL : systemresource:/ZIP3/+/tram.hs
> > Help Set tram not found : java.lang.NullPointerException
> > java.lang.NullPointerException
> >         at javax.javahelp.HelpSet.<init>(HelpSet.java:76)
> >         at iscsbJPanel.<init>(iscsbJPanel.java:32)
> >         at iscsbHelp.<init>(iscsbHelp.java:36)
> >         at iscsbHelp.main(iscsbHelp.java:55)
> >
> > Could someone please tell me what I need to do to just load a simple
> > HelpSet
> > or some sample working code ?
> >
> > Tram Nguyen N.
> > Science Application International Corporation
> > http://www.saic.com
> > (619) 646-3357


Take me off you email list! I no longer need help on JAVA.

Reply via email to