Search:

Type: Posts; User: Norm

Search: Search took 0.29 seconds.

  1. Replies
    13
    Views
    1,593

    Re: PrintStream, strings and reading from a file.

    At line 17 the code has used an index with the value -1 which is invalid. Valid indexes range in value from 0 to the length of the String -1. Look at line 17 and see why it is using an index of -1....
  2. Replies
    13
    Views
    1,593

    Re: PrintStream, strings and reading from a file.

    Can you make a small test program with a String that has the < and > and has the logic you are working with?
    The FileWriter class isn't needed for debugging problems parsing a String.


    That...
  3. Replies
    13
    Views
    1,593

    Re: PrintStream, strings and reading from a file.

    The String class has methods for finding Strings within another String. Use a method to Find the "<" and then find the ">".
  4. Replies
    13
    Views
    1,593

    Re: PrintStream, strings and reading from a file.

    You don't need to write anything to a file to test the String replacement logic.
    Write a small test program
    Define a String with the delimited Strings.
    Write the logic to do the replacements....
  5. Replies
    13
    Views
    1,593

    Re: PrintStream, strings and reading from a file.

    Comment: Using a single letter like f for a variable name makes it hard to "Search" the source to see where the variable is used. A longer, unique name would make it easier.

    Where is the...
Results 1 to 5 of 5