两个简单问题!
1:
string a = "1001.0200";
请问怎么把他按人民币的格式打印?如1001.02只保留两个小数?
2:
在cs文件里生成一个table
System.Web.UI.WebControls.Table tab_ShopCar
TableRow tr = new TableRow();
TableCell tc1 = new TableCell();
tc1.Width = 59;
//居中对齐------------------------------
tc1.HorizontalAlign = "center";
//--------------------------------------
tr.Cells.Add(tc1);
tab_ShopCar.Rows.Add(tr);
*********************************************************************
//居中对齐------------------------------
tc1.HorizontalAlign = "center";这句报错:c:\inetpub\wwwroot\UsersInfo\ShopCar.aspx.cs(68): 无法将类型“string”隐式转换为“System.Web.UI.WebControls.HorizontalAlign”
请问怎么做啊?
//--------------------------------------