Foxtable(狐表)用户栏目专家坐堂 → 从字符串“增加开piao”到类型“Boolean”的转换无效


  共有1779人关注过本帖树形打印复制链接

主题:从字符串“增加开piao”到类型“Boolean”的转换无效

帅哥哟,离线,有人找我吗?
elfing
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:幼狐 帖子:90 积分:1202 威望:0 精华:0 注册:2015/4/25 9:42:00
从字符串“增加开piao”到类型“Boolean”的转换无效  发帖心情 Post By:2018/8/7 15:11:00 [只看该作者]

代码如下

Dim lx As String = e.Form.Controls("类型").value
Dim rq As WinForm.DateTimePicker = e.Form.Controls("日期")
Dim je As WinForm.NumericComboBox = e.Form.Controls("金额")
Dim hk As WinForm.DateTimePicker = e.Form.Controls("回款日期")
Dim kh As WinForm.ComboBox = e.Form.Controls("客户")
Dim gy As WinForm.ComboBox = e.Form.Controls("供应商")

If Tables("应收应付").Current IsNot Nothing Then
    Tables("应收应付").Current.Save()
End If

If lx = "增加开piao" Then
    If lx = False Or rq.Value = False Or je.Value = False Or hk.Value = False Or kh.Value = False Then
        MessageBox.Show("请完善信息!")
    Else
        Dim dr As DataRow = DataTables("应收应付").AddNew()
        dr("类型") = lx
        dr("单位") = kh.Value
        dr("日期") = rq.Value
        dr("应收增加") = je.Value
        dr("回款日期") = hk.Value
    End If
End If

Tables("应收应付").Sort = "日期 DESC"
[此贴子已经被作者于2018/8/7 15:12:09编辑过]

 回到顶部
帅哥哟,离线,有人找我吗?
有点甜
  2楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:版主 帖子:85326 积分:427815 威望:0 精华:5 注册:2012/10/18 22:13:00
  发帖心情 Post By:2018/8/7 15:35:00 [只看该作者]

 

If lx = nothing Or rq.Value = nothing Or je.Value = nothing Or hk.Value = nothing Or kh.Value = nothing Then

 


 回到顶部