hi myself jaipal deshwal
my problem is that i am not find proper value in dropdownlist
the coding is as folow
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
public partial class _Default : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
DropDownList1.Items.Add("-Select-");
DropDownList1.Items.Add("+");
DropDownList1.Items.Add("/");
DropDownList1.Items.Add("*");
DropDownList1.Items.Add("-");
}
}
protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e)
{
int a = Int32.Parse(TextBox1.Text);
int b = Int32.Parse(TextBox2.Text);
if(DropDownList1.SelectedItem.Text='+')
{
int c = a + b;
TextBox3.Text = c.ToString();
}
}
}
and when i run it it not run because it show tha
unable to convert char to string value