Hi,

Let's take the following scenario: we have a database which manage car
models (for example Dogde Viper). The column "name" of the "car model"
table must be unique.
The user wants to add a "car model" in the database, thus he has an "add
screen" containing all the fields of the "car model" and a "Save"
button. However he has entered a model which already exists in the
database. I check that in my business layer and return a runtime
exception "name already exists".
I can display it using global-exceptions, however it is forwarded to
another page and consequently, the user must reenter all the field
values one more time.
To avoid that, I want to go back to the "add screen" without losing user
inputs but with a red message "name already exists in the database" -
exactly like the struts validation error messages.

Do you think it is possible with Struts 2? I have used that lots of time
in Struts 1.

Thanks in advance,

Jeremy 

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

Reply via email to