Avatar of baileytibbs
baileytibbsFlag for Afghanistan

asked on 

An ASP programming question relating to a select form field on a web page

Hi,

We have a very basic ASP web site created by a supporter.  One of the admin pages enable us to edit events and one of the fields in the edit page is a drop down list of venues taken from a venue table in our database.  The actual code for this section is as below

<td class="title">Event Venue</td>
      <td><select name="Venue" size="1">
      <% Do While Not oRP.EOF%>
      Response.Write "<OPTION VALUE="<%=oRP("ID")%>"><%=oRP("Venue")%></option>
      <%oRP.Movenext
      Loop%>
        &nbsp;
      </select>

This works fine when we are adding an event and hence can select a venue from the drop down list, but is not so good when we are editing an event, as the venue previously selected is not shown as a selected option.  Hence, the editor has to remember to reselect the venue before pushing the make changes button.  If they don't remember then the venue that is first in the drop down list is selected by default.

It is not a big deal but i was hoping that cleverer people than us might have a solution so that drop down list defaults to the venue previously selected but does allow us to select others from the database if a change is needed.

Thanks
Scripting LanguagesASP

Avatar of undefined
Last Comment
hc0904pcd
ASKER CERTIFIED SOLUTION
Avatar of hc0904pcd
hc0904pcd
Flag of Australia image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of hc0904pcd
hc0904pcd
Flag of Australia image

hi Bailey - just to tidy thigns up, could you please either close this question, or continue it?
thanks.
ASP
ASP

Active Server Pages (ASP) is Microsoft’s first server-side engine for dynamic web pages. ASP’s support of the Component Object Model (COM) enables it to access and use compiled libraries such as DLLs. It has been superseded by ASP.NET, but will be supported by Internet Information Services (IIS) through at least 2022.

82K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo