TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Sbonga Mathobela
NA
68
7.5k
How to use Jquery for getting values from Dropdown
Apr 11 2017 3:07 AM
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.
Reply
Answers (
3
)
get request.header from basic authentication
Pdf View conversation failed