vb.net Arraylist去重

前端之家收集整理的这篇文章主要介绍了vb.net Arraylist去重前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
Public Function FilterRpeat(ByVal allUrls As ArrayList,ByVal SysType As String) As Integer '去除重复函数,返回判断值
        Dim Lst_Domains As New ArrayList
        Dim Value_Chongfu As cboItemValue
        Dim sys As String = String.Empty
        Dim int_judge As Integer
        Lst_Domains = allUrls
        sys = SysType
        int_judge = 1
        For Each Value_Chongfu In Lst_Domains
            If Value_Chongfu.Value.ToString = sys.ToString Then
                int_judge = 0
                Exit Function
            End If
        Next
        Return int_judge
    End Function
'arraylist调用函数 
 For int_LoopCnt = 0 To ArraySize(astr_SysTypes) - 1
            If (FilterRpeat(aobj_ItemList,astr_SysTypes(int_LoopCnt)) = 1) Then
                aobj_ItemList.Add(New cboItemValue(astr_SysTypes(int_LoopCnt),astr_SysTypes(int_LoopCnt),int_LoopCnt + 1,False))
            End If
        Next
原文链接:https://www.f2er.com/vb/256569.html

猜你在找的VB相关文章