Connecting Tech Pros Worldwide Forums | Help | Site Map

Problem while Refresh.

Newbie
 
Join Date: Jun 2009
Posts: 4
#1: Jun 19 '09
Hai Everybody,

I am new to Java coding; I want to solve a problem in Jsp and servlet. Here I am having a pop in main-form, when the pop is pressed it will pass to the sub-form. After filling the sub-form it will back to main form.

My problem is, while I am getting a value from the sub-form to main-form, the page is refreshing. It is ok, but the value already in the main-form textboxes gets disappeared. But I want the buffer value at same textbox after refreshing. I don’t know what to do. Please help me to solve this problem....

Lots of Thanks in Advance....

JosAH's Avatar
Expert
 
Join Date: Mar 2007
Posts: 10,611
#2: Jun 20 '09

re: Problem while Refresh.


Quote:

Originally Posted by prodigyjohn View Post

Hai Everybody,

I am new to Java coding; I want to solve a problem in Jsp and servlet. Here I am having a pop in main-form, when the pop is pressed it will pass to the sub-form. After filling the sub-form it will back to main form.

My problem is, while I am getting a value from the sub-form to main-form, the page is refreshing. It is ok, but the value already in the main-form textboxes gets disappeared. But I want the buffer value at same textbox after refreshing. I don’t know what to do. Please help me to solve this problem....

Lots of Thanks in Advance....

When you're working with Servlets and JSPs remember that the traffic always goes from the client to the server and vice versa; there is no way to go 'back', so if you want to give the impression that you go 'back' from the sub form to the main form you have to populate the fields in the main form again; it's the responsibility of the servers, nothing automagically 'remembers' those field values for you.

kind regards,

Jos
Newbie
 
Join Date: Jun 2009
Posts: 4
#3: Jul 2 '09

re: Problem while Refresh.


Then how cam I populate the fields in the main form again. Please give me any idea.
Newbie
 
Join Date: Jul 2009
Posts: 2
#4: Jul 2 '09

re: Problem while Refresh.


You can try to store them in session data before they are changed.
Newbie
 
Join Date: Jun 2009
Posts: 4
#5: Jul 6 '09

re: Problem while Refresh.


Can you please, tell me how to store them in session data before they are changed.
Reply