If e.DataCol.Name = "年份" Then
Dim cns() As String = {"一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"}
If e.NewValue = Nothing Then
For Each cn As String In cns
e.DataRow(cn) = Nothing
Next
Else
Dim filter = "[保洁员] Is null"
For i As Integer = 0 To cns.Length - 1
Dim d As Date = new Date(Date.Today.Year, i+1, 1)
e.DataRow(cns(i)) = DataTables("派工表").compute("sum(单价2)", filter & " and 日期 >= #" & d & "# and 日期 < #" & d.AddMonths(1) & "#")
Next
End If
End If
此主题相关图片如下:qq图片20150410110518.png

我想按月份实时统计出销售情况,不知道问题在哪里,没实现。。。求解