以文本方式查看主题 - Foxtable(狐表) (http://foxtable.net/bbs/index.asp) -- 专家坐堂 (http://foxtable.net/bbs/list.asp?boardid=2) ---- SQLTable Select语句 (http://foxtable.net/bbs/dispbbs.asp?boardid=2&id=101289) |
-- 作者:zoyong -- 发布时间:2017/5/27 17:10:00 -- SQLTable Select语句 SQLTable Select语句 Select * F rom {cn_xjrjz} Where fdate Is Null窗口AfterLoad Dim y As Integer = Date.Today.Year Dim m As Integer = Date.Today.Month Dim dt1 As New Date(y, m, 1) Dim dt2 As New Date(y, m, Date.DaysInMonth(y, m)) \'获取本月的最后一天 Dim Filter As String Filter = "FDate >= \'" & dt1 & "\' And FDate <= \'" & dt2 & "\'" \'SQL表格式 DataTables("cn_xjrjz_Table1").LoadFilter = Filter \'设置加载条件 DataTables("cn_xjrjz_Table1").Load() \'加载数据 Dim tv As WinForm.TreeView \'树目录赋值 tv =e.Form.Controls("TreeView1") tv.BuildTree("cn_xjrjz", "FYear|FPeriod") Dim nd As WinForm.TreeNode nd = tv.Nodes.Insert("显示全部",0) 窗口按键加载60天数数据 Dim dt As Date = Date.Today.AddDays(-60) DataTables("cn_xjrjz").LoadFilter = "FDate > \'" & dt & "\'" DataTables("cn_xjrjz").Load() \' Dim tv As WinForm.TreeView \'树目录赋值 tv =e.Form.Controls("TreeView1") tv.BuildTree("cn_xjrjz", "fdate|FPeriod") Dim nd As WinForm.TreeNode nd = tv.Nodes.Insert("显示全部",0) 为什么上面的代码,只显示一张空表
|
-- 作者:有点蓝 -- 发布时间:2017/5/27 17:58:00 -- 窗口AfterLoad Dim y As Integer = Date.Today.Year Dim m As Integer = Date.Today.Month Dim dt1 As New Date(y, m, 1) Dim dt2 As New Date(y, m, Date.DaysInMonth(y, m)) \'获取本月的最后一天 Dim Filter As String Filter = "FDate >= \'" & dt1 & "\' And FDate <= \'" & dt2 & "\'" \'SQL表格式 DataTables("cn_xjrjz_Table1").LoadFilter = Filter \'设置加载条件 DataTables("cn_xjrjz_Table1").Load() \'加载数据 Dim tv As WinForm.TreeView \'树目录赋值 tv =e.Form.Controls("TreeView1") tv.BuildTree(DataTables("cn_xjrjz_Table1"), "FYear|FPeriod") Dim nd As WinForm.TreeNode nd = tv.Nodes.Insert("显示全部",0) 窗口按键加载60天数数据 Dim dt As Date = Date.Today.AddDays(-60) DataTables("cn_xjrjz_Table1").LoadFilter = "FDate > \'" & dt & "\'" DataTables("cn_xjrjz_Table1").Load() \' Dim tv As WinForm.TreeView \'树目录赋值 tv =e.Form.Controls("TreeView1") tv.BuildTree(DataTables("cn_xjrjz_Table1"), "fdate|FPeriod") Dim nd As WinForm.TreeNode nd = tv.Nodes.Insert("显示全部",0)
|