If I have an array that a function uses, how can I pass it a variable and get back the output depending on which array # I pass it as well?
E.G.
So if I want JUST the data from the first array, how can I set that parameter in my click event?
E.G.
Code:
Public Function GetInfo(ByVal pstrMyVariable As String) As String()
Dim strSomeOutput = GetOutputFunction(pstrMyVariable)
For Each strLine As String In strSomeOutput.Split(ControlChars.Lf)
If strLine.Length > 0 Then
Dim arrLine() As String
arrLine = strLine.Split(","c)
Return arrLine
End If
Next
Return Nothing
End Function
Private Sub btnClick_Click(sender As Object, e As EventArgs) Handles btnClick.Click
Dim strMyVariable As String = txtRandom.Text
decSomeDecimal = GetInfo(strMyVariable) 'and here is where I want to pass an array # also
End Sub