Search:

Type: Posts; User: Norm

Search: Search took 0.14 seconds.

  1. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    Great. I am glad you got it working.
  2. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    I think only 1 close is required. The API doc for the close method says: Closes the stream, flushing it first.


    Have you solved the problem?
  3. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    That statement says the path to the logger file is "". Where is that location????

    Note this statement:

    if ("".equals(logFile)) return;

    Try this with a good path in the...
  4. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    Move the IConsole class's definition outside of the Logger class (past the line: } // end of class Logger) at the end of the source file.


    That is my code for testing.
    What is in your code on...
  5. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    You keep skipping these questions:


    The command needs to be: java Logger
    not Java IConsole.

    Change the source by putting the IConsole class at the end of the source file.
    Also add the word...
  6. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    Also these questions about how the Logger program is used in the Dukascopy environment:

    Why do you think the Logger class is usable? Where did you get it?

    If you did not write the code, how...
  7. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    The name of your version of the class is Logger. That is what you need to use in the main method, not BobsLogger.
    For my testing I changed it to BobsLogger to keep from having a confusing class in...
  8. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    The structure of the source file needs fixing. The structure should be like this:
    class statement {
    fields for the class
    method declarations with {}s
    } at end of class

    Start with the code in...
  9. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    Can you post the actual code in the logger.java file that you passed to the javac.exe command?

    --- Update ---

    I am done for tonight. I'll be back tomorrow.
  10. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    Stand alone.
  11. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    We are testing the code in the Logger class to find the problem you are having. The rest of the code is not needed for the test.

    Here is a version of IConsole for testing:

    class IConsole { ...
  12. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    No. The flush clears any data left in the buffer.

    Did you make a small, complete class with a main that can be compiled and executed for testing to demonstrate the problem?
    Please post it and the...
  13. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    I usually add a main method to simple utility classes like this to allow easy standalone testing. Here is an example of the one I used with your code. It allows both of us to execute the same code...
  14. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    Where is a main method for testing the code?
    What is printed on the console when the code is executed?
  15. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    I get this when I execute the code:

    Are you sure you put a call to printStackTrace in all the catch blocks?
  16. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    Have you solved your problem now?
  17. Replies
    35
    Views
    1,347

    Re: can't seem to find the log

    Are there any exceptions thrown? Empty catch blocks ignore any exception.

    catch (IOException e) {}
    Add a call to printStackTrace to the catch blocks to print a message/trace if there is an...
Results 1 to 17 of 17