Avatar of 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.

<div class="row">
    <div class="grid1">&nbsp;</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">
                        <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 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>
                        <input class="vlistvalue" tabindex="47" label="Room" style="width:300px;" type="text">

Open in new window


Avatar of undefined
Last Comment
Julian Hansen

8/22/2022 - Mon
Julian Hansen

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
This is the best money I have ever spent. I cannot not tell you how many times these folks have saved my bacon. I learn so much from the contributors.