mock5c
asked on
setting value in complex structure
I've encountered a structure such as the one in the code snippet I'm pasting. How can I set the values within any of the dropdowns (region, building, or room). For example, I would like to set Building C as the selected item or set room to 444.
I would like to accomplish this using jquery.
I would like to accomplish this using jquery.
<div class="row">
<div class="grid1"> </div>
<div class="grid10">
<input style="height: 1px; width: 1px; border: medium none; padding: 0px; margin: 0px; visibility: hidden;" tabindex="-1" value="1|Building B|222" title="Region, Building, Room" id="room" class="manadd" type="hidden">
<table id="roomvaluelist" class="picktable valuelist">
<thead>
<tr>
<th>Region</th>
<th>Building</th>
<th>Room</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<select tabindex="45" class="s_large vlistvalue" label="Region" nodbform="true" style="width:200px;">
<option value="">Select...</option>
<option value="1">1</option>
<option value="2">2</option>
<option value="3">3</option>
</select>
</td>
<td>
<select tabindex="46" class="s_small vlistvalue" label="Building" style="width:200px;">
<option value="">Select...</option>
<option value="Building A">Building A</option>
<option value="Building B">Building B</option>
<option value="Building C">Building C</option>
</select>
</td>
<td>
<input class="vlistvalue" tabindex="47" label="Room" style="width:300px;" type="text">
</td>
</tr>
</tbody>
</table>
</div>
</div>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.