【发布时间】:2011-04-07 10:11:09
【问题描述】:
我有一个更新函数,它通过数据集更新 sql server db 表。表中的字段之一是整数并接受空值。因此,当我填充更新函数时,我需要一种在函数需要整数时输入 null 的方法。
我试图这样做,但_intDLocation = "" 抛出异常
Dim _dLocation As String = udDefaultLocationTextEdit.Text
Dim _intDLocation As Integer
If _dLocation <> "" Then
_intDLocation = Integer.Parse(udDefaultLocationTextEdit.Text)
Else
'NEED HELP HERE
_intDLocation = ""
End If
【问题讨论】: