3 Replies Latest reply: Feb 6, 2010 11:33 PM by 843810 RSS

    Setting BasicNativeContentViewerUI  results into Error

    843810
      Hi All,

      I am trying to use BasicNativeContentViewerUI in my swing application to view help files.
           
       SwingHelpUtilities.setContentViewerUI("javax.help.plaf.basic.BasicNativeContentViewerUI");        
      But i am getting the error "ContentViewerClass javax.help.plaf.basic.BasicNativeContentViewerUI doesn't exist"
      Here is the code snippet:
        try {
                  java.net.URL url = null;
                  url = HelpSet.findHelpSet(this.getClass().getClassLoader(), "Help/MyHelpSet.hs");
                  hs = new HelpSet(null, url);
                  
                  if(hs != null)
                      SwingHelpUtilities.setContentViewerUI("javax.help.plaf.basic.BasicNativeContentViewerUI");
                  
                  hb = hs.createHelpBroker();
                  hb.setSize(new java.awt.Dimension(800, 700));
                  hb.setCurrentID("About");
                 menuItem.addActionListener(new CSH.DisplayHelpFromSource(hb));
              } catch (Exception e) {
                  System.out.println("Error : " + e.toString());
              }
      Thanks
      Nani