I have one more question
i made a code like this for changing characters in a string to another
charahcter
public String passreturn(String username)
{
Char[] sifre = { 'a', 'b', 'c', 'd', 'e', 'f',
'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'r', 's', 't', 'u',
'v', 'w', 'x', 'y', 'z' };
Char[] crypt = { 'n', 'o', 'p', 'q', 'r', 's',
't', 'u', 'v', 'w', 'x', 'y', 'z', '{', '|', '}', '', '!',
'\"', '#', '$', '%', '&', '\'', '('};
int i=0;
String cryptedpw="";
for (int j = 0; j < 11;j++ )
{
if (sifre[j] == username &&
i <= username.Length-1)
{
cryptedpw = cryptedpw + crypt[j];
i++;
j = -1;
}
}
return (cryptedpw);
}
but the characters after z like % & ' is not proccesing
for example when i send the word dakka
its returning this [b:881676c071]qnnxn[/b:881676c071] but when i send
the word [b:881676c071]dakkar[/b:881676c071] its still returning
[b:881676c071]qnxxn[/b:881676c071] instead
[b:881676c071]qnxxn[/b:881676c071]
How can i fix this are there any ascii protection in c#