Hi all.

I have written a C++ code to modify a string, the code is:

Code:
int Len = (nString.length());   
char *szString = (char*)(nString.c_str()); // Convert to C string 
	
for (int i = 0; i < Len; i++)        
{
 *(szString+i) = (*(szString+i) + 123);     //XOR
}
Can someone help me convert this to VB:

I have this so far, but it is not working:
Code:
        Dim i As Integer
        Dim chrArray() As Char

        chrArray = EncryptIn.ToCharArray

        For intCounter = 0 To chrArray.Length - 1
            chrArray(i) = chrArray(i + 123)
         Next
Thanks bunch!