I believe the parameter action takes a parameter to determine which worker
method to call. Are you using an Action that extends ParameterAction
somewhere in your application? I don't believe it is called unexplicitly.
Could be wrong.

"Unknown Source" in the stack trace just means that the line number was not
available from the version of ParameterAction class the servlet container
was using.

B

> -----Original Message-----
> From: Caroline Jen [mailto:[EMAIL PROTECTED] 
> Sent: Thursday, May 13, 2004 6:45 PM
> To: [EMAIL PROTECTED]
> Subject: findSuccess(Unknown Source)!!
> 
> 
> Need your expertise to diagnose the problem.
> 
> I have a java class ListThread.java that extends
> Action.  This java class simply calls a couple of
> helper classes to access my database.
> 
> I have not yet prepared a JSP to be displayed in the
> browser after ListThread.java completes its tasks;
> therefore, upon completion, I temporarily wants the
> application to be forwarded to my welcome page.  (My
> welcome page works fine.)
> 
> I got Status 500 error:
> 
> java.lang.NullPointerException
>       at 
> org.apache.struts.scaffold.ParameterAction.findSuccess(Unknown
> Source)
> 
> 
> My struts-config.xml looks like:
> 
>     <action
>         roles="administrator,editor,contributor"
>         path="/message/ListThreads"
>         type="org.apache.artimus.message.ListThread"
>         name="articleForm"
>         scopte="request"
>         validate="false">
>        <forward
>             name="success"
>             path="/signin/Welcome.jsp"/>
>     </action>
> 
> And here is my ListThread.java:
> 
> import LOTS OF PACKAGES AND CLASSES;
> 
> public final class ListThread extends Action
> {
>    public ActionForward execute(ActionMapping mapping,
>                                 ActionForm form,
>                                 HttpServletRequest
> request,
>                                 HttpServletResponse
> response)
>                                 throws Exception 
>    {
> 
>       String memberName = request.getRemoteUser();
> 
>       // for sort and order stuff
>       String sort  = request.getParameter( "sort" );
>       String order = request.getParameter( "order" );
> 
>       if ( sort.length() == 0 ) sort =
> "ThreadLastPostDate";
>       if ( order.length()== 0 ) order = "DESC";
> 
>       int offset  = 0;
>       int rows    =
> MessageInboxConfig.ROWS_IN_THREADS;
>       offset = Integer.parseInt( request.getParameter(
> "offset" ) );
>       rows = Integer.parseInt( request.getParameter(
> "rows" ) );
> 
>       ListThreadHandler lthandler = new
> ListThreadHandler();
>       ListPostHandler lphandler = new
> ListPostHandler();
> 
>       int totalThreads = 
> lthandler.getNumberOfThreads_forReceiver( memberName );
>       if ( offset > totalThreads ) 
>       {
>          throw new BadInputException( "The offset is
> not allowed to be greater than total rows." );
>       }
> 
>       Collection beans = 
> lthandler.getThreads_forReceiver_withSortSupport_limit(
> memberName, offset, rows, sort, order );
> 
>       SiteUtil.prepareNavigate( request, offset,
> beans.size(), totalThreads,
> MessageInboxConfig.ROWS_IN_THREADS );
>       int totalPosts =
> lphandler.getNumberOfPosts_forReceiver( memberName );
> 
>       request.setAttribute( "ThreadBeans", beans );
>       request.setAttribute( "TotalThreads", new
> Integer( totalThreads ) );
>       request.setAttribute( "TotalPosts", new Integer( totalPosts ) );
> 
>       return ( mapping.findForward( "success" ) );
> 
>    }
> }
> 
> 
> 
> 
> 
>       
>               
> __________________________________
> Do you Yahoo!?
> Yahoo! Movies - Buy advance tickets for 'Shrek 2' 
http://movies.yahoo.com/showtimes/movie?mid=1808405861 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to