以文本方式查看主题 - Foxtable(狐表) (http://foxtable.com/bbs/index.asp) -- 专家坐堂 (http://foxtable.com/bbs/list.asp?boardid=2) ---- 遍历行 (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=187314) |
-- 作者:shqpldczj -- 发布时间:2023/7/8 11:57:00 -- 遍历行 Dim r As Date = Date.now For Each dr2 As DataRow In DataTables("合同主表").DataRows Dim r2 As Date = dr2("合同到期日") Dim t As TimeSpan = r2 - r dr2("合同到期状态") = Format(t.TotalDays,"###") Next DataTables("合同主表").save msgbox("重算完毕1") 请教我如果只想计算核算列为空的行条件怎么加,谢谢
|
-- 作者:有点蓝 -- 发布时间:2023/7/8 13:27:00 -- For Each dr2 As DataRow In DataTables("合同主表").DataRows 改为 For Each dr2 As DataRow In DataTables("合同主表").select("核算 is null")
|