Solved

How to debug statement "IntraLearnLogOnMgr mgr = new IntraLearnLogOnMgr();"

Posted on 2004-03-22
4
217 Views
Last Modified: 2010-04-01
I just started to create a test page. I have this line that causes my page to bomb:

IntraLearnLogOnMgr mgr = new IntraLearnLogOnMgr();


I don't know where to start or how to debug this. I'm importing everything I need but I get a :

We're sorry, but the page you requested could not be found. (acts as if ipage doesn't exist)

I don't do a lot of java or JSP.  What steps should i take to  figure out what's wrong?

//////////////////////////////////////////////////////////////////
complete code
//////////////////////////////////////////////////////////////////

<%@ page import="java.sql.*,java.util.*,java.io.*,javax.servlet.*,javax.servlet.http.*,java.net.*,com.brocade.intralearn.*" %>
<%
      String connString = "thunder";
      String userId=(String)request.getHeader("SM_USER");
      
      Hashtable params = new Hashtable();
      IntraLearnLogOnMgr mgr = new IntraLearnLogOnMgr();
      Connection con = mgr.getConnection(connString);
      Registered reg = mgr.profileExist(con, params, userId);
      
%>

userId: <%=userID%>
<br><br>
REGISTRATION STATUS:<%=reg%>
0
Comment
Question by:894359
4 Comments
 

Author Comment

by:894359
ID: 10653864
correction; userId: <%=userId%>
0
 
LVL 4

Expert Comment

by:kokchoon78
ID: 10654526
Do u mean this statment "IntraLearnLogOnMgr mgr = new IntraLearnLogOnMgr();" cause the error ? If you are using tomcat, u can simply check the tomcat's log file.

How if you remove / comment out the "IntraLearnLogOnMgr mgr = new IntraLearnLogOnMgr();", the page shown ?

show us the code for the IntraLearnLogOnMgr ?
0
 
LVL 13

Accepted Solution

by:
copyPasteGhost earned 500 total points
ID: 10654618
if you make a java bean out of the IntraLearnLogOnMgr class

then it will work
if you use this...

<jsp:useBean class="com.brocade.intralearn.IntraLearnLogOnMgr " id="mgr" scope="page"/>
<%@ page import="java.sql.*,java.util.*,java.io.*,javax.servlet.*,javax.servlet.http.*,java.net.*,com.brocade.intralearn.*" %>
<%
     String connString = "thunder";
     String userId=(String)request.getHeader("SM_USER");
     
     Hashtable params = new Hashtable();
     Connection con = mgr.getConnection(connString);
     Registered reg = mgr.profileExist(con, params, userId);
     
%>

userId: <%=userID%>
<br><br>
REGISTRATION STATUS:<%=reg%>

Also be sure that your IntraLearnLogOnMgr.class file is located in this directory

WEB-INF/classes/com/brocade/intralearn/IntraLearnLogOnMgr.class

also all your .jsp files must be at the same level as the WEB-INF folder
Hope that helps,
ghost
0
 
LVL 14

Expert Comment

by:kennethxu
ID: 10655022
what app server r u using. I agree with ghost, but the .jsp file location can be anywhere inside your webapp except WEB-INF.

also, I would suggest to start from a simple jsp page with no code in

xyz.jsp:
<%@ page import="com.brocade.intralearn.*" %>
this is xyz.jsp page

if you get this page loaded then add a line to see if it gives you any error:

xyz.jsp:
<%@ page import="com.brocade.intralearn.*" %>
this is xyz.jsp page
<%     IntraLearnLogOnMgr mgr = new IntraLearnLogOnMgr(); %>
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Performance in games development is paramount: every microsecond counts to be able to do everything in less than 33ms (aiming at 16ms). C# foreach statement is one of the worst performance killers, and here I explain why.
Owning a franchise can be the dream of a lifetime. It provides a chance for economic growth. You can be as successful as you want.  To make your franchise successful, you need to market it successfully. Here are six of the best marketing strategies …
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now