C# Split用法
string str = "1_01,2_02,3_03,4_04";
string[] s1 = str.Split(',');
string s2 = "";
for (int i = 0; i < s1.Length; i++)
{
s2 = s1[i].ToString().Split('_')[0];
Response.Write("<script>alert(" + s2 + ")</script>");
}
浙公网安备 33010602011771号