Here are some steps I compiled for the guys at work. Note: WEB-INF for struts will automatically be recognized as a web-module. (There is no talk of struts below). Also note that the list of steps is for an older release 3.3 beta 6. The latest release of netbeans may not need all of the steps.
hope it helps someone (a lot of this was compiled by searching through the netbeans mailing list and the netbeans site should really be updated with some of this information at some point...) Getting Servlet Debugging to Work: Netbeans 3.3.6. 1. Download jdk1.3.1_01 and install. 2. Create an environment variable java_home and point to the install directory (eg: d:\jdk1.3.1) 3. Download and install Netbeans 3.3.6 (3.3 beta 6) 4. Since this Netbeans does not contain an installation process update the ide.cfg file in the <netbeans install directory>\bin\ide.cfg. 5. Update this file to contain reference to the jdkhome variable: -jdkhome d:\jdk1.3.1 -J-Xverify:none -J-Xms24m -J-Xmx96m 6. Mount a fileSystem if one is not already mounted. 7. Right click and select: New\JSP & Servlet\Web Module 8. A classes directory should have been created. 9. Right click the classes directory and choose New\JSP & Servlet\Servlet 10. In the processRequest method - create a simple output like "Hello World" 11. Compile the servlet. The target for the compilation is not set and so it will default to the current directory which is fine. To see this: Tools/Options/Building/Compiler Types/External Compilation/Target. To see which compilation is being used: Tools/Options/Building/JSP&Servlet/Default JSP&Servlet Compiler. 12. Right click on a line in the processRequest() method and select Toggle Breakpoint. 13. A breakpoint should be visible. 14. Right click on the servlet and select properties. 15. Check the URI parameter of the servlet. 16. Select the "WEB-INF" directory that was created after step 7. 17. Go to the menu and select "Debug-Start" 18. This should launch Internet Explorer (If it doesn't - go to Tools/Options/Building/JSP&Servlet and change the Web Browser parameter). 19. The web browser will have a url like: http://localhost:8080 (The port that the internal tomcat listens on can be changed: Tools/Options/Debugging & Executing/Execution Types/J2EE Server Executor and select Installed Servers. A server Registry should open up when you can select: Server Registry/Installed Servers/Tomcat 3.2 The properties box lists which port is applicable). 20. Tack on the URI parameter determined in step #14. Additional steps for jsp debugging 21. Set a break point in the jsp you want to: Right click on the jsp and select View\Servlet. Place the cursor where you want the break point and select Debug\Add Breakpoint Change the type from "Class" to "Line" in the dialog box that pops up and select ok. Note: The breakpoint will not be visible. To remove the breakpoint -- go to the debugging tab. --- Michael Mok <[EMAIL PROTECTED]> wrote: > Hi Dave > > Yes it should work with Netbeans 3.3. > > Regards > > Michael Mok > > > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, 16 January 2002 2:55 > To: Struts Users Mailing List; > [EMAIL PROTECTED] > Subject: RE: Execute Struts in Netbeans? > > > > > Has anyone produced a similar HOW-TO for Netbeans? > Or will this work for > Netbeans as well as Forte? > > Cheers, > > Dave > > > > > > "Michael Mok" > <[EMAIL PROTECTED]> > on > 01/14/2002 > 02:24:27 AM > > Please respond to "Struts Users Mailing List" > > <[EMAIL PROTECTED]>; > Please respond > to > > [EMAIL PROTECTED] > > To: "'Struts Users Mailing List'" > > <[EMAIL PROTECTED]> > cc: (bcc: David Hay/Lex/Lexmark) > Subject: RE: Execute Struts in Netbeans? > > > > I have written a HOW-TO on this. You may want to > read it first. > > www.michaelmok.com > > Michael Mok > Product Manager > FullyBooked > 1306 Hay Street > West Perth > Western Australia 6005 > Tel: 61 8 93221295 > Fax: 61 8 94815281 > Email: [EMAIL PROTECTED] > www.fullybooked.com.au > > -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED]] > Sent: Saturday, 12 January 2002 10:41 > To: [EMAIL PROTECTED] > Subject: RE: Execute Struts in Netbeans? > > If you use Forte 3.0 CE (same as netbeans with a few > extensions -- good web > app extensions), running Struts apps is no problem. > > -----Original Message----- > From: AJ Morris [mailto:[EMAIL PROTECTED]] > Sent: Friday, January 11, 2002 4:14 PM > To: [EMAIL PROTECTED] > Subject: Execute Struts in Netbeans? > > > Has anyone had luck executing struts-based > applications in the Netbeans > integrated Tomcat? Things are fine with the > standalone Tomcat, but not the > internal Tomcat. > > Here are the issues. Tomcat can't see the taglibs, > but this is solved by > mounting struts.jar. Tomcat will not execute action > mappings, because it > says the path is not valid. Tomcat cannot see my > ApplicationProperties > files, either. > > AJ Morris > [EMAIL PROTECTED] > > > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > > > > > > > > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > __________________________________________________ Do You Yahoo!? Send FREE video emails in Yahoo! Mail! http://promo.yahoo.com/videomail/ -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>