奇怪,我的Compute 统计记录的值是 0
Dim s01 As Integer
Dim jsz1 As WinForm.Label = e.Form.Controls("lan_jsz_count")
Dim ok1 As WinForm.Label = e.Form.Controls("lan_ok_count")
Dim sum1 As WinForm.Label = e.Form.Controls("lan_sum_count")
Dim yq1 As WinForm.Label = e.Form.Controls("lan_yq_count")
messagebox.show(Tables(e.form.name & "_Table4").Rows.Count) <--------------------------这个结果是 5
s01=Tables(e.form.name & "_Table4").Compute("count[m_sn_no]","[m_state] = '进行中'") <--------------------------这个结果是 0
jsz1.Text=s01
s01=Tables(e.form.name & "_Table4").Compute("count[m_sn_no]","[m_state] = '完成'") <--------------------------这个结果是 0
ok1.Text=s01
s01=Tables(e.form.name & "_Table4").Compute("count[m_sn_no]","[m_state] = '逾期'") <--------------------------这个结果是 0
yq1.Text=s01
s01=Tables(e.form.name & "_Table4").Compute("count[m_sn_no]","[m_state] <> '1'") <--------------------------这个结果是 0
sum1.Text=s01
说明 :m_sn_no 是会议编号,其中“进行中”的会议有 1 项,“逾期”“ 的有 2 项,”完成“的 2 项。
请教老师,我应该如何更正上面的代码?
谢谢!