• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Devaka Cooray
  • Liutauras Vilda
  • Jeanne Boyarsky
Sheriffs:
  • Knute Snortum
  • Junilu Lacar
  • paul wheaton
Saloon Keepers:
  • Ganesh Patekar
  • Frits Walraven
  • Tim Moores
  • Ron McLeod
  • Carey Brown
Bartenders:
  • Stephan van Hulst
  • salvin francis
  • Tim Holloway

pass the value to next form  RSS feed

 
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have made two forms. The first one has a drop down list. it takes the value from the database. When i click on submit it takes me to another form. There is a drop down list in the other form which again retrieves value from the database. it also has a textbox. I want the value of the textbox to be equal to the selected option of the first form. These are my codes.


2nd form




I have used string.getParameter and retrieved the value of the drop down list and stored in String variable name. When i put that in the value of the textbox the selected option doesnt appear!!
 
Ranch Hand
Posts: 874
Android Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator



Firstly , Do not use Scriplets in JSP, Submit to Servlet , and use Utility class to get DB operations and send teh result to JSP to display it.

For your current problem , to access scriplet variable use <%=name%> instead of "name" in the above case
 
author
Posts: 4096
21
Eclipse IDE Flex Google Web Toolkit
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
DO NOT PUT JDBC CODE INSIDE OF JSP. It's a sign of a really really bad developer.

I swear this is going to become my catch phrase.
 
Sujay Nadkarni
Ranch Hand
Posts: 34
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks balu and scott!! it worked!!
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!