VB判断Integer为空问题
我从数据库里读出最大值
当此值不存在(也就是数据库里为空)
然后去判断我取出来的 reader.GetInt32(0)为空
有没有类似C#里的 NULL判断
[解决办法]
看看这个例子:
Dim i As Integer
i = Asc(vbNullChar) '这里是给integer变量赋Null值
If Chr(i) = vbNullChar Then
MsgBox "明白了吧 ", vbOKOnly, "提示 "
End If