Hey guys i was just wonder how i would do this; i need to supply a value for Counts() in the triples function how would i do this to check all values in the array?

Private Counts() As Integer = {two, three, four, five, six, seven, eight, nine, ten, eleven, twelve}



    Function Triples() As Boolean
        'check if counts is 3
        If Counts() < 3 Then
            Return False
        ElseIf Counts() >= 3 Then
            Return True
        End If


    End Function

Recommended Answers

All 2 Replies

try

    For Each Value In Counts
        If Value = "Three" Then
        'do something
        Else
        'do something else
        End If
    Next

thanks alot thats what i needed :)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.