一:
/// <判断是不是数字>
/// 判断是不是数字
/// </summary>
private bool IsNumber(string strvalue)
{
int i = 0;
int j = 0;
string strTemp = "1234567890";
for (i = 0; i < strvalue.Length; i++)
{
j = strTemp.IndexOf(strvalue.Substring(i, 1));
if (j == -1)
{
return false;
}
}
return true;
}
二:下拉框字典邦定:
DataSet ds = new DataSet();
CommonLogic clsLogic = new CommonLogic();
//获取查询类型信息
ds = clsLogic.GetCodeInfo("010", string.Empty, string.Empty);
//查询类型绑定
cmbCxlx.DataSource = ds.Tables[0];
cmbCxlx.DataTextField = "NAME";
cmbCxlx.DataValueField = "CODE";
cmbCxlx.DataBind();
三: