If(dropdownlist1.selectedIndexChanged==true)
{
//code
}
else
{
//code
}
I am getting error in If condition, so can u pls give me a
solution.
Answer Posted / gaurav k
SelectedIndexChanged is a event for the DropDown Control.
True is a bool type. We can not compare an event with bool
type like this. If we have to do somthing on the change of
the selection of an item, we can write the appropriate code
in the SelectedIndexChanged Event.
protected void DropDownList1_SelectedIndexChanged
(object sender, EventArgs e)
{
//Code
}
Is This Answer Correct ? | 11 Yes | 0 No |
Post New Answer View All Answers
What is the difference between application state and session state in asp net?
Can you explain composite pattern?
How is the asp.net mvc architecture different from others? : asp.net mvc
How to fetch a data from one table to another table in asp.net ?
Differentiate between structure and class.
Explain the use of dataadapter.
Explain the boxing and unboxing concept in .net?
List the asp.net validation controls?
Give an example of cookie abuse.
What is the benefit of WebAPI over WCF?
Which method is used to enforce garbage collection in .net?
What is different authentication mechanisms used in ASP.NET?
How to improve performance of web application asp.net mvc? : Asp.Net MVC
When we use cookie less session? Explain its working?
what is a .xap file? Explain with an example.