Problem developing application on NetBeans Platform

Karan <[email protected]>
Newsgroups gmane.comp.java.ide.netbeans.user,gmane.comp.java.netbeans.user-interface
Message-ID <[email protected]>
Hi,

I wrote a "HelloWorld" example application to demonstrate using the 
NetBeans platform, based on some instructions from this website: 
http://www.javalobby.org/java/forums/t17711 This module runs perfectly, 
creating a menu entry named HelloWorld and popping up a dialog box when 
its clicked.

Then I copied off all the HelloWorld code into another directory 
HelloWorld2 so that I could mess around in this new module HelloWorld2. 
I made changes to the code and other files as required for this new 
module. Following is the code:

manifest.mf in HelloWorld2:
Manifest-Version: 1.0
OpenIDE-Module: helloworld2/1
OpenIDE-Module-IDE-Dependencies: IDE/1 > 3.17
OpenIDE-Module-Layer: helloworld2/resources/mf-layer.xml
OpenIDE-Module-Specification-Version: 1.0

mf-layer.xml in HelloWorld2/src/helloworld2/resources:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE filesystem PUBLIC "-//NetBeans//DTD Filesystem 1.1//EN" 
"http://www.netbeans.org/dtds/filesystem-1_1.dtd">
<filesystem>
<folder name="Menu">
  <folder name="HelloWorld2">
    <file name="helloworld2-actions-HelloWorldAction2.instance"/>
  </folder>   </folder>
</filesystem>

HelloWorldAction2.java in HelloWorld2/src/helloworld2/actions:
package helloworld2.actions;
import org.openide.util.HelpCtx;
import org.openide.util.actions.CallableSystemAction;
import javax.swing.JOptionPane;

public class HelloWorldAction2 extends CallableSystemAction {

  public HelpCtx getHelpCtx() {
      return HelpCtx.DEFAULT_HELP;
  }

  public String getName() {
      return "Say HelloWorld2";
  }
 
  public void performAction() {
      String msg = "Hello World 2";
      JOptionPane.showMessageDialog(null,msg);
  }
}

This module, is just not working. It will compile and bring up the gui, 
but it does not add a HelloWorld2 menu item to the gui as expected. I 
have gone over the code files again and again and can't figure out the 
problem. Please help me out if you can.

I do not want to make a module for the NetBeans IDE, I want to make an 
independent application which is based on the NetBeans platform, 
something like Minex. I want to modify the menus, toolbar and add in 
some existing modules, but I'm not sure how to do all this. Any help is 
greatly appreciated.

Thanks.

Regards,
Karan
-- 
-- never compromise. what if you compromise and lose? --
NS & DCA (CM II)
Resolution Systems Inc.
U.S.A.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.