It's possible the error occurred on the line before the snippet, or that decrypted is an int (though that should give a different error). Can you provide the declaration for decrypted and index? Maybe I can help if I see more.
Give a man a fish, he'll eat for one day. Teach a man to fish, he'll drink all your beer.
Cheers, Jeff (SCJP 1.4, SCJD in progress, if you can call that progress...)
Hi, You generally get this error if you are using the .operator on a primitive. eg int i; i.(any function) will give you this error. Which is why you need to use wraper classes to perform those operations.
Whats the datatype of index?
Joined: Jul 30, 2003
I created the following test program from your code, and it worked fine: