Tech
Forums
Jobs
Books
Events
Live
Interviews
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
3
Reply
How to use Jquery for getting values from Dropdown
Sbonga Mathobela
Apr 11 2017 3:07 AM
202
Reply
Hi All
I have a dropdown that binds with Database and here is the code:
var stat = db.tb_Status.ToList();
ddltype.DataSource = stat;
ddltype.DataTextField = "Status";
ddltype.DataValueField = "Status_Id";
ddltype.DataBind();
ddltype.Items.Insert(0, new ListItem("Select Vehicle Status"));
Its working fine now i want a script to allow me if I select items from the dropdown some buttons must hide and others show. here is the View code:
<div class="form-group">
<label for="usr"><b>Vehicle Status:</b></label>
<div>
<asp:DropDownList ID="ddltype" runat="server" required="true" class="form-control" Width="250px" Height="34px"></asp:DropDownList>
</div>
</div>
I managed to hide them initially like this:
$("[id*=btnAdd]").hide();
I want them to show depending on selected value on the dropdown.
Please Assist.
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
3
)
Next Recommended Forum
get request.header from basic authentication
Pdf View conversation failed