Friday, February 10, 2012

Using Hashtable in asp.net

Hashtable hlist = new Hashtable();
hlist["applno"] = txtapplicationno.Text;
hlist["Flatno"] = txtflatno.Text;
hlist["Flatstataus"] = ddlflatstatus.SelectedValue;
hlist["Customername"] = txtcname.Text == "" ? string.Empty : txtcname.Text; //ternary operator in asp.net
hlist["amount"] = float.Parse(txtreceivedamt.Text);
string dueamt = txtdueamount.Text == "0" ? "0" : txtdueamount.Text;   //ternary operator in asp.net

No comments:

Post a Comment

Comments

Search

Custom Search
Protected by Copyscape Plagiarism Software