If forms("日新车队").opened Then
Dim r As Row = e.Table.Current
If r IsNot Nothing Then
If r("二保日期") >= Date.Today AndAlso r("营运证年审") >= Date.Today AndAlso r("靠挂费日期") >= Date.Today Then
forms("日新车队").Controls("TextBox23").Text = "正常"
Else If r("二保日期") < Date.Today AndAlso r("营运证年审") >= Date.Today AndAlso r("靠挂费日期") >= Date.Today Then
forms("日新车队").Controls("TextBox23").Text = "漏保"
Else If r("二保日期") < Date.Today AndAlso r("营运证年审") < Date.Today AndAlso r("靠挂费日期") >= Date.Today Then
forms("日新车队").Controls("TextBox23").Text = "漏保|漏审"
Else If r("二保日期") >= Date.Today AndAlso r("营运证年审") < Date.Today AndAlso r("靠挂费日期") < Date.Today Then
forms("日新车队").Controls("TextBox23").Text = "漏审|漏费"
Else If r("二保日期") >= Date.Today AndAlso r("营运证年审") < Date.Today AndAlso r("靠挂费日期") >= Date.Today Then
forms("日新车队").Controls("TextBox23").Text = "漏审"
Else If r("二保日期") >= Date.Today AndAlso r("营运证年审") >= Date.Today AndAlso r("靠挂费日期") < Date.Today Then
forms("日新车队").Controls("TextBox23").Text = "漏费"
Else If r("二保日期") < Date.Today AndAlso r("营运证年审") >= Date.Today AndAlso r("靠挂费日期") < Date.Today Then
forms("日新车队").Controls("TextBox23").Text = "漏保|漏费"
Else
forms("日新车队").Controls("TextBox23").Text = "漏保|漏审|漏费"
End If
Forms("日新车队").Controls("TextBox22").text = DataTables("日新车队").Compute("count(二保日期)", "二保日期 < #" & Date.Today & "#")
Forms("日新车队").Controls("TextBox21").text = DataTables("日新车队").Compute("count(二保日期)", "二保日期 >= #" & Date.Today & "#")
Forms("日新车队").Controls("TextBox20").text = DataTables("日新车队").Compute("count(车号)")
Forms("日新车队").Controls("TextBox24").text = Tables("日新车队").Compute("count(营运证年审)", "营运证年审< #" & Date.Today & "#")
Forms("日新车队").Controls("TextBox25").text = Tables("日新车队").Compute("count(靠挂费日期)", "靠挂费日期 >= #" & Date.Today & "#")
Else
forms("日新车队").Controls("TextBox23").Text = Nothing
Forms("日新车队").Controls("TextBox22").text = Nothing
Forms("日新车队").Controls("TextBox21").text = Nothing
Forms("日新车队").Controls("TextBox20").text = Nothing
Forms("日新车队").Controls("TextBox24").text =Nothing
Forms("日新车队").Controls("TextBox25").text =Nothing
End If
End If