Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to access Errors in Action class .....

 
Pras Tiwari
Ranch Hand
Posts: 186
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am developing My web app using Struts1.1 . Now I have A login page (embedding Login form bean) with corresponding action class(LoginAction.java). Now currently when user enters correct Username & password he is getting transferred to his account page successfully. But I want to add one more thing in above login action class:-
When user enters wrong login info , the error Object should be created into action class & it should be but into ActionErrors. & then user should get forwarded to original login page with appropriate error messages in front of Login & Passowrd textboxes on Login page.
Hope u understand my problem.
How should I do that?
Pls help me.
Thanx
pras
 
Merrill Higginson
Ranch Hand
Posts: 4864
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You should be able to find the answer to this question by reading the section entitled "Displaying Error Message" in this link.

This link also has some good information on using messages in Struts.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic