aspose file tools*
The moose likes JSP and the fly likes How to set selected value to combobox after refreshing page Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "How to set selected value to combobox after refreshing page" Watch "How to set selected value to combobox after refreshing page" New topic
Author

How to set selected value to combobox after refreshing page

Dipti Lokhande
Greenhorn

Joined: May 05, 2007
Posts: 9
JSP design is as follows:

Student Type : combo-box which contains different types (PartTime, FullTime)
Student ID : text field whr user enters Student ID
Student Name : text filed which displays Student name
:
:
:


In the above application, Student name is retrieved from database &
passing parameters StudentType & StudentID. This is happened on onBlur
event of the StudentID text field.

Now here I'm facing problem as , when student name is displayed on the
form, selected student type is being lost & it sets to the default
student type ie 1st one as I want to restore it.

Please tell me what should I do to resolve this issue.
Expecting reply asap.

Thanks in advance.
sudhir nim
Ranch Hand

Joined: Aug 29, 2007
Posts: 212

You can use SELECTED property.



[Servlet tutorial] [Servlet 3.0 Cook Book]
Ben Souther
Sheriff

Joined: Dec 11, 2004
Posts: 13410

Originally posted by Dipti Lokhande:

Expecting reply asap.


Please keep in mind that everyone answering questions here is a volunteer and that nobody should ever be expected to do anything, let alone on any sort of time frame.

See this to find out why sentences like this (or adding 'Urgent' to your posts) can actually turn helpful people away; slowing down or halting responses to your questions altogether.


Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to set selected value to combobox after refreshing page