- Код: Выделить всё
Public Const Pass = "P@sSwoRd123456789"
Dim Ky() As Byte
Dim Mx As Integer
Dim KeyMap() As Byte
Private Const MaxStringLength = 65536 'максимальная длинна текста
Sub InitCryptMap()
On Error Resume Next
Ky = StrConv(Pass, vbFromUnicode)
Mx = UBound(Ky) + 1
ReDim KeyMap(MaxStringLength - 1)
For i = 0 To MaxStringLength - 1
KeyMap(i) = Ky(i Mod Mx)
Next
Mx = Mx - 1
End Sub
Function Compile$(ByRef AnyString As String)
Dim i& , Cs() As Byte
Cs = StrConv(AnyString, vbFromUnicode)
For i = 0 To UBound(Cs)
Cs(i) = Cs(i) Xor KeyMap(i)
Next
Compile = StrConv(Cs, vbUnicode)
End Function
ругается на строку: Cs(i) = Cs(i) Xor KeyMap(i)
подскажите что делать