这个不能用表达式统计的,首先你要将这些表达式列改为数据列:
http://www.foxtable.com/help/topics/2494.htm
然后做个统计按钮,按钮的代码为:
For Each dr As DataRow In DataTables("管理人员下井考核表").DataRows
dr("中班_实际") = DataTables("管理人员下井考勤").Compute("Count([_Identify])","姓名 = '" & dr("姓名") & "' And 班次 = '中' And 下井时间 Is Not Null")
dr("夜班_实际") = DataTables("管理人员下井考勤").Compute("Count([_Identify])","姓名 = '" & dr("姓名") & "' And 班次 = '夜' And 下井时间 Is Not Null")
dr("八小时_实际") = DataTables("管理人员下井考勤").Compute("Count([_Identify])","姓名 = '" & dr("姓名") & "' And 班次 = '中' And 时长 > 28800")
Next
这种类型的统计,可以参考帮助的:
http://www.foxtable.com/help/topics/0681.htm