Handling errors in Struts

V

vyshu

hi,

I am devoloping an
application using struts.I am facing some problems in handling
errors.Let me expain my situation.I have two forms in diffrent jsp
pages.On the click of submit,I am processing the data in a single
Action Servlet.In my action mapping i can specify only one page as the
value for the attribute "input".so in case of any errors,I am not able
to redierct to the exact input page.

any comments?

thanks,
vysh
 
S

Sanjay

vyshu said:
hi,

I am devoloping an
application using struts.I am facing some problems in handling
errors.Let me expain my situation.I have two forms in diffrent jsp
pages.On the click of submit,I am processing the data in a single
Action Servlet.In my action mapping i can specify only one page as the
value for the attribute "input".so in case of any errors,I am not able
to redierct to the exact input page.

any comments?

thanks,
vysh

If I understand you correctly, let me ask you this, what is stopping you
from adding two separate action mappings? For example

<action path="/blah1" type="blah.blah.action1"
.....
.....
input="/yada1.jsp"
</action>

<action path="/blah2" type="blah.blah.action1"
....
....
input="yada2.jsp"
</action>
 
V

vyshu

If I understand you correctly, let me ask you this, what is stopping you
from adding two separate action mappings? For example

<action path="/blah1" type="blah.blah.action1"
.....
.....
input="/yada1.jsp"
</action>

<action path="/blah2" type="blah.blah.action1"
....
....
input="yada2.jsp"
</action>

Thanks a lot for your reply sanjay.yeah,i did the same!.
ok,this is done.
But yesterday i just got messed up with new one.
I have an form for updating the customer details.when ever the user
say submit,it calls the action and performs the updation.Now comes my
problem,I want to redirect back to the same update page with the newly
updated values.I think you got what i meant.
Let me be specific,Can i call an action from another action?.If its
possible please do reply me.
waiting for your suggestions.
thanks,
vysh.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top