Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

Explain client-side scripting?

996


What are the advantages of asp.net?

1005


ASP.NET 2.0's new membership API used for creating and managing user account is exposed through which 2 clause?

1928


Why is the standalone environment only useful during the development process?

1835


How can we register exception filter from the action?

1083


Is it possible to apply themes to an asp.net application? If yes, then how?

1022


8. Why do you want to work here?

1926


Give 2 examples for scenarios when routing is not applied?

1057


Explain exception filters?

1036


How do active server pages work?

984


Tell me what is the request flow used for asp.net mvc framework? : asp.net mvc

1110


Explain advantages of caching?

937


What is the caspol.exe tool used for?

1016


What role “#&&” plays in a querysting?

1019


Explain managed code an un-managed code.

1035