aspose file tools*
The moose likes Struts and the fly likes Form Bean Error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Form Bean Error" Watch "Form Bean Error" New topic
Author

Form Bean Error

Saravanan Mrajan
Greenhorn

Joined: Jun 28, 2009
Posts: 18
I have an Input.jsp which is validated using form bean's ActionErrors validate() method and the error messages are displayed fine.

The problem that i am facing is, after getting the error messages on the same page, the values i entered before got disappeared and the empty form is shown with the error messages.

How to keep the values on the form with the error messages?
Sagar Rohankar
Ranch Hand

Joined: Feb 19, 2008
Posts: 2902
    
    1

Post your JSP with mapping and Action Form, you're using.


[LEARNING bLOG] | [Freelance Web Designer] | [and "Rohan" is part of my surname]
Saravanan Mrajan
Greenhorn

Joined: Jun 28, 2009
Posts: 18
I got the Solution.

Thank you very much For trying.
Sagar Rohankar
Ranch Hand

Joined: Feb 19, 2008
Posts: 2902
    
    1

Happy to know that and I didn't try anything.
Saravanan Mrajan
Greenhorn

Joined: Jun 28, 2009
Posts: 18
Sagar Rohankar wrote:Happy to know that and I didn't try anything.


It's Ok. i just want to restrict entering characters in the form by writing code inside the formbean's validation method. but it's not working exactly. i am searching for it in the net. please let me know if you know.

Thanks!
Sagar Rohankar
Ranch Hand

Joined: Feb 19, 2008
Posts: 2902
    
    1

Saravanan MahaRaj wrote:I just want to restrict entering characters in the form by writing code inside the formbean's validation method.

You mean the form field will accept only characters like, a to z, then I thinks its simple. A simple Regex or for loop for any characters other than alphabet can solve your problem.
Saravanan MahaRaj wrote: but it's not working exactly.

Please tell the details, what you have done and what you get and what you have expected ??
Saravanan Mrajan
Greenhorn

Joined: Jun 28, 2009
Posts: 18
Sagar Rohankar wrote:
Saravanan MahaRaj wrote:I just want to restrict entering characters in the form by writing code inside the formbean's validation method.

You mean the form field will accept only characters like, a to z, then I thinks its simple. A simple Regex or for loop for any characters other than alphabet can solve your problem.
Saravanan MahaRaj wrote: but it's not working exactly.

Please tell the details, what you have done and what you get and what you have expected ??


Thanks. Again I got it fixed.
Sagar Rohankar
Ranch Hand

Joined: Feb 19, 2008
Posts: 2902
    
    1

And again welcome
Saravanan Mrajan
Greenhorn

Joined: Jun 28, 2009
Posts: 18
Sagar Rohankar wrote:And again welcome


Hi

i want to calculate the time taken beteen a request (sent to the webserver) and response (from the webserver) in my struts application. what is the way i can go with?
Sagar Rohankar
Ranch Hand

Joined: Feb 19, 2008
Posts: 2902
    
    1

This is the third question you're asking in same thread, please create the separate thread for each doubt/question and keep the original thread topic intact.

And about the your requirement:
There is no standard API / method which gives you the time difference between the request sent and received to the client, but you can always rely on Firebug addon for FireFox to get the time for each resource it request from server, also the same functionality has been there in Google Chrome browser.


HTH
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Form Bean Error