Clear Output Pane

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Kid Programmer
    New Member
    • Mar 2008
    • 176

    Clear Output Pane

    Is there a method I can use to delete all the text that has been outputted using the
    System.out.prin tln(""); method?
  • BigDaddyLH
    Recognized Expert Top Contributor
    • Dec 2007
    • 1216

    #2
    No in a platform-independent way. The simplest thing is to be happy with printing a few blank lines.

    Comment

    • Kid Programmer
      New Member
      • Mar 2008
      • 176

      #3
      Originally posted by BigDaddyLH
      No in a platform-independent way. The simplest thing is to be happy with printing a few blank lines.
      Okay. Thanks amigo.

      Comment

      • BigDaddyLH
        Recognized Expert Top Contributor
        • Dec 2007
        • 1216

        #4
        Originally posted by Kid Programmer
        Okay. Thanks amigo.
        Yeah, keep it simple and save the fun and games for Swing...

        Comment

        • r035198x
          MVP
          • Sep 2006
          • 13225

          #5
          You could of course "clear" the visible screen by printing lots of blank lines

          [CODE=java]void clrscr () {
          for(int i = 0; i < 100;i++) {
          System.out.prin tln("");
          }
          }[/CODE]

          Comment

          • Kid Programmer
            New Member
            • Mar 2008
            • 176

            #6
            Originally posted by r035198x
            You could of course "clear" the visible screen by printing lots of blank lines

            [CODE=java]void clrscr () {
            for(int i = 0; i < 100;i++) {
            System.out.prin tln("");
            }
            }[/CODE]
            Okay that could work. The user could just scroll back up but whatever.

            Comment

            • JosAH
              Recognized Expert MVP
              • Mar 2007
              • 11453

              #7
              ps. you can also google for 'jcurses'.

              kind regards,

              Jos

              Comment

              Working...