I'm having trouble with the above error message. I'm converting string input from a textbox to a char array. I then pass the array to a function. The error occurs in the function call itself. I don't understand why though. I've converted the string to a char array - haven't I?
The program worked fine until I added the option strict on statement to prevent late binding. Now I have a lot of problems.
Thank you in advance for your help.
Dim romanInput As String romanInput = inputTextBox.Text.Trim. Dim array() As Char = romanInput.ToCharArray romanToArabicConversion = convertToArabicThousands(array(), j) Public Function convertToArabicThousands(ByVal array() As Array, ByRef j As Integer) As Integer arabicThousandsResult = 0 j = 0 With Me If j < array.Length Then Select Case array(j) Case Is "M" If array.Length - j >= 4 And arabicThousandsResult <= 4000 Then If array(j) Is "M" And array(j + 1) Is "M" And array(j + 2) Is "M" And array(j + 3) Is "M" Then arabicThousandsResult = arabicThousandsResult + 4000 j = j + 4 End If End If End Select End If End With Return arabicThousandsResult End Function

New Topic/Question
Reply



MultiQuote




|