Hi,
I'm translating some code from C++ to C#,
but I don't know how to change the code below to get it working under C#
...., I've tried explicity convertion, but without any results :(
Please help....
int b = -1;
uint a,c = 0;
Encoding encodingAscii = Encoding.GetEncoding(1250);
Encoding encodingUnicode = Encoding.Unicode;
unchecked
{
for (int i=0;i<multiParam.Length;i++)
{
byte[] unicodeBytes = encodingUnicode.GetBytes(multiParam[i]);
byte[] asciiBytes =
Encoding.Convert(encodingUnicode,encodingAscii,uni codeBytes);
for (int j=0;j<asciiBytes.Length;j++)
{
c = asciiBytes[j];
//the problem starts here...
a = (c ^ b) + (c << 8);
b = (a >> 24) | (a << 8);
}
}
}
Regards.