求助:采用内部函数定义了一个任务栏数据统计定义 窗体启动后会刷新一次 当数据修改保存后及时刷新一次 任务栏信息出现重复 求纠正代码 谢谢
此主题相关图片如下:1.jpg
此主题相关图片如下:2.jpg
收发文基础信息 内部函数代码如下
Dim fll As WinForm.TopicBar = Forms("收文登记").Controls("收文登记信息一览")
Dim ly As WinForm.TopicPage = fll.Pages("文件来源")
For Each wjly As String In DataTables("系统词典").GetComboListString("内容","类型 = '文件来源' ","_Identify" ).Split("|")
Dim kg As String = new String (" ",15-wjly.Length*2)
ly.Links.Add(wjly,wjly & kg & "(" & DataTables("收发文基础信息").Compute("count(_identify)","文件来源 = '" & wjly & "'") & "件)" )
Next
Dim dw As WinForm.TopicPage = fll.Pages("文件单位")
For Each wjdw As String In DataTables("系统词典").GetComboListString("内容","类型 = '文件单位' ","_Identify" ).Split("|")
Dim kg As String = new String (" ",10-wjdw.Length)
dw.Links.Add(wjdw,wjdw & kg & "(" & DataTables("收发文基础信息").Compute("count(_identify)","文件单位 = '" & wjdw & "'") & "件)" )
Next
Dim dw1 As WinForm.TopicPage = fll.Pages("文件密级")
For Each wjdw1 As String In DataTables("系统词典").GetComboListString("内容","类型 = '文件密级' ","_Identify" ).Split("|")
Dim kg As String = new String (" ",15-wjdw1.Length*2)
dw1.Links.Add(wjdw1,wjdw1 & kg & "(" & DataTables("收发文基础信息").Compute("count(_identify)","文件密级 = '" & wjdw1 & "'") & "件)" )
Next
Dim dw2 As WinForm.TopicPage = fll.Pages("文件类型")
For Each wjdw2 As String In DataTables("系统词典").GetComboListString("内容","类型 = '文件类型' ","_Identify" ).Split("|")
Dim kg As String = new String (" ",15-wjdw2.Length*2)
dw2.Links.Add(wjdw2,wjdw2 & kg & "(" & DataTables("收发文基础信息").Compute("count(_identify)","文件类型 = '" & wjdw2 & "'") & "件)" )
Next
Dim dw3 As WinForm.TopicPage = fll.Pages("经办人名")
For Each wjdw3 As String In DataTables("系统词典").GetComboListString("内容","类型 = '经办人名' ","_Identify" ).Split("|")
Dim kg As String = new String (" ",15-wjdw3.Length*2)
dw3.Links.Add(wjdw3,wjdw3 & kg & "(" & DataTables("收发文基础信息").Compute("count(_identify)","经办人名 = '" & wjdw3 & "'") & "件)" )
Next
[此贴子已经被作者于2014-12-5 0:59:03编辑过]