获得CheckBoxList中选定的值
string MobileServices = "";
for (int i = 0; i < MobileService.Items.Count; i++)
{
if (MobileService.Items[i].Selected == true)
if (MobileServices=="")
MobileServices += "1";
else
MobileServices += "_1";
else
if (MobileServices == "")
MobileServices += "0";
else
MobileServices += "_0";
}
这样获得的MobileServices是一个类似 "1_0_1_1"的字符串

浙公网安备 33010602011771号