int类型数据没办法判断它是否为空,只能判断它是否为0或其他整型值,如果是string类型,这个可以判断,string strInfo=string.empty;if(strInfo == string.Empty || strInfo == null){}