C
Coz
Hi all,
I'm looking for help again!!! I have been writing a page to update a
database but now have another 'silly' problem with listbox's...Grrr...
I'm trying to populate the list box with static values pre-programmed into
the page and then set the listbox value to that of the one contained in the
database for that particular record the code I'm using is -
<select name="SelectGarage">
<option value="0">No</option>
<option value="1">Yes</option>
<option value="2">Yes (Two)</option>
The listbox comes up OK and the value contained in the database is
displayed, but if the number '1' (for Yes) is the value stored in the record
to be edited, the value is displayed as a '1' and not a 'yes'. I don't want
it to actually add the value in the record, I want it to select the
corresponding label i.e. '1' = 'Yes'.
Can anyone help........
Cheers
Coz
I'm looking for help again!!! I have been writing a page to update a
database but now have another 'silly' problem with listbox's...Grrr...
I'm trying to populate the list box with static values pre-programmed into
the page and then set the listbox value to that of the one contained in the
database for that particular record the code I'm using is -
<select name="SelectGarage">
<option value="0">No</option>
<option value="1">Yes</option>
<option value="2">Yes (Two)</option>
</select><%=(CPEditPropertyRS.Fields.Item("Garage").Value)%></option>
The listbox comes up OK and the value contained in the database is
displayed, but if the number '1' (for Yes) is the value stored in the record
to be edited, the value is displayed as a '1' and not a 'yes'. I don't want
it to actually add the value in the record, I want it to select the
corresponding label i.e. '1' = 'Yes'.
Can anyone help........
Cheers
Coz