Search:

Type: Posts; User: KevinWorkman

Search: Search took 0.08 seconds.

  1. [SOLVED] Re: backspace action(deleting a character in a string) in a paint event, looping for

    Keep in mind that Strings are immutable- that means they never change. You can get certain substrings or characters from a String, but the original remains intact.
  2. [SOLVED] Re: backspace action(deleting a character in a string) in a paint event, looping for

    Yep, you could have just done word = word.substring(0, word.length()-1); or something like that.
  3. [SOLVED] Re: backspace action(deleting a character in a string) in a paint event, looping for

    Those seem like reasonably approaches. Or you could use a StringBuilder.

    But think about the word growing in terms of an int. What you have is basically this:

    int limit = 5;
    for(int i = 0; i <...
  4. [SOLVED] Re: backspace action(deleting a character in a string) in a paint event, looping for

    Yeah, that is going to loop forever. Think about what you're doing- you're looping until the end of the word, but each iteration, you're adding a character to the word. That means you'll never be...
Results 1 to 4 of 4