Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

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

Posted on 2004-03-22
4
Medium Priority
?
226 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 2000 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

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

High user turnover can cause old/redundant user data to consume valuable space. UserResourceCleanup was developed to address this by automatically deleting user folders when the user account is deleted.
In a use case, a user needs to close an opened report by simply pressing the Escape (Esc) key. This can be done by adding macro code in Report_KeyPress or Report_KeyDown event.
this video summaries big data hadoop online training demo (http://onlineitguru.com/big-data-hadoop-online-training-placement.html) , and covers basics in big data hadoop .
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…

885 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