Forum Moderators: open
I have a web form in my application.
I have added a dropdown list to that form.
Now in the code behind, I have declared an array with five values.
I want to fill that dropdownlist with the array values. The code in the code behind is as follows:
public partial class _Default : System.Web.UI.Page
{
public string[] arrData ={ "This", "That", "and", "the", "other" };
protected void Page_Load(object sender, EventArgs e)
{
Page.DataBind();
}
}
Please suggest me with the necessary changes as I am getting the following error "System.StackOverflowException was unhandled"
Thanks for the help.