以文本方式查看主题 - Foxtable(狐表) (http://www.foxtable.com/bbs/index.asp) -- 专家坐堂 (http://www.foxtable.com/bbs/list.asp?boardid=2) ---- format处理字段时应该怎么写才对? (http://www.foxtable.com/bbs/dispbbs.asp?boardid=2&id=61137) |
-- 作者:有点甜 -- 发布时间:2014/12/7 20:50:00 -- Dim dr As DataRow dr = DataTables("考勤表").Find("编号 = \'" & e.Form.Controls("TextBox1").Text & "\' and 时段=\'上午\' and 年月=\'" & Format(e.Form.Controls("dateTimePicker1").value, "yyyyMM") & "\'") |
-- 作者:有点甜 -- 发布时间:2014/12/7 20:52:00 -- dr("借资金额")= DataTables("借支表").Compute("Sum(借支金额)","[编号] = \'" & r("编号") & "\' and 日期 >= #" & new Date(2014, 11,1) & "# and 日期 < #" & new Date(2014, 12, 1) & "#") [此贴子已经被作者于2014-12-7 21:01:24编辑过]
|
-- 作者:有点甜 -- 发布时间:2014/12/7 20:52:00 -- 看3楼 |
-- 作者:有点甜 -- 发布时间:2014/12/7 20:58:00 -- 想办法根据字符生成日期 |
-- 作者:有点甜 -- 发布时间:2014/12/7 21:01:00 -- 年月就行啊
Dim d As Date = new Date(年, 月,1) dr("借资金额")= DataTables("借支表").Compute("Sum(借支金额)","[编号] = \'" & r("编号") & "\' and 日期 >= #" & d & "# and 日期 < #" & d.AddMonths(1) & "#") [此贴子已经被作者于2014-12-7 21:00:55编辑过]
|