VBcoders Guest



Don't have an account yet? Register
 


Forgot Password?



The code list out numbers from the text of Text1 (TextBox)

by Dipen Anovadia (19 Submissions)
Category: Miscellaneous
Compatability: Visual Basic 5.0
Difficulty: Unknown Difficulty
Originally Published: Thu 25th August 2005
Date Added: Mon 8th February 2021
Rating: (1 Votes)

The code list out numbers from the text of Text1 (TextBox)

Rate The code list out numbers from the text of Text1 (TextBox)



'instead of text box...
Sub ListOutNumbers()

    Dim sChr As String
    Dim i As Integer

    If Text1 = "" Then Exit Sub
    List1.Clear

    For i = 0 To Len(Text1)
        sChr = Mid(Text1, i + 1, 1)
        If IsNumeric(sChr) Then List1.AddItem sChr
    Next i
End Sub


Download this snippet    Add to My Saved Code

The code list out numbers from the text of Text1 (TextBox) Comments

No comments have been posted about The code list out numbers from the text of Text1 (TextBox). Why not be the first to post a comment about The code list out numbers from the text of Text1 (TextBox).

Post your comment

Subject:
Message:
0/1000 characters