Hi Ahmet,

Your code is throwing a NullPointerException because you are
attempting to use a reference that has not been initialized (other
than to null). In your generateNewName method, newName is declared and
initialized to null. In the for loop that follows you attempt to
assign a value to the first element of the newName char array, but it
is not an array at this point, it is null. You need to find some way
to initialize your char array before entering the for loop. Once you
do the NullPointerException will clear up.

Hope this helped.

Happy coding!
Geoff.

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/javaprogrammingwithpassion?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to