Reputation: 469
Form example I would like to create method that request any TextBox1.text , I write
void method(Textbox text)
{ }
But when I would like create method that request any dropdownlist, which type should I specify in the method ?
void method(Type dropdownlist)
{ }
Type= ?
Upvotes: 2
Views: 329
Reputation: 223277
Since its ASP.Net
I believe you need DropDownList Class
void method(DropDownList dropdownlist)
{
}
Remember to include using System.Web.UI.WebControls;
Upvotes: 1