列表框重新排列字符串

时间:2017-10-22 01:05:39

标签: vb.net listbox

当我尝试在列表框中添加字符串时:

    Do While sReader.Peek >= 0
        Dim line As String = (sReader.ReadLine)
        If line.Contains(":") Then
            line = line.Split(":")(1)
        End If
    For Each character As Char In line
            If Char.IsUpper(character) = True Then
                passToMask = passToMask & "?" & "u"
            ElseIf Char.IsLower(character) = True Then
                passToMask = passToMask & "?" & "l"
            ElseIf Char.IsNumber(character) = True Then
                passToMask = passToMask & "?" & "d"
            ElseIf Char.IsPunctuation(character) Then
                passToMask = passToMask & "?" & "s"
            ElseIf Char.IsSymbol(character) = True Then
                passToMask = passToMask & "?" & "s"
            ElseIf Char.IsWhiteSpace(character) = True Then
                passToMask = passToMask & "?" & "s"
            End If
        Next
        NewMask.Add(TextBox2.Text)
        Label1.Text = Label1.Text - 1
        Label3.Text = NewMask.Count()
        TextBox2.Text = ""
    Loop

    For Each mask In NewMask

        ListView1.Items.Add(mask)
    Next

它向后添加字符串d?d? 我想要的是什么?d?d 我已经移动了passToMask = passToMask& “?” &安培; “l”传递ToMask = passToMask +“?l” 它只是不断切换订单。列表框也未排序。

1 个答案:

答案 0 :(得分:0)

看来,当它是一个字符串时,您只需使用select * from dba_network_acls

此外,您可以通过读取字符串的方式控制将字符串添加到字符串的行为。

只需使用

anyString.Reverse()