Text delay

Discussion in 'Java' started by K, Oct 19, 2012.

  1. K

    K Guest

    Does anyone know how to make certain text in a java application delay and display after the previous text
    K, Oct 19, 2012
    #1
    1. Advertising

  2. K

    Eric Sosman Guest

    On 10/19/2012 1:15 PM, K wrote:
    > Does anyone know how to make certain text in a java application delay and display after the previous text


    System.out.println("the previous text");
    try {
    Thread.sleep(desired_delay_in_milliseconds);
    } catch (InterruptedException ex) {
    System.out.println("This may be premature, but:");
    }
    System.out.println("certain text");

    In other words, you'll get no better answer today than you did
    three days ago unless you explain your situation more clearly.

    --
    Eric Sosman
    d
    Eric Sosman, Oct 19, 2012
    #2
    1. Advertising

  3. On 19/10/2012 19:15, K allegedly wrote:
    > Does anyone know how to make certain text in a java application delay
    > and display after the previous text


    Yes.

    --
    DF.
    Daniele Futtorovic, Oct 19, 2012
    #3
  4. K

    bob smith Guest

    On Friday, October 19, 2012 12:49:32 PM UTC-5, Eric Sosman wrote:
    > On 10/19/2012 1:15 PM, K wrote:
    >
    > > Does anyone know how to make certain text in a java application delay and display after the previous text

    >
    >
    >
    > System.out.println("the previous text");
    >
    > try {
    >
    > Thread.sleep(desired_delay_in_milliseconds);
    >
    > } catch (InterruptedException ex) {
    >
    > System.out.println("This may be premature, but:");
    >
    > }
    >
    > System.out.println("certain text");
    >
    >
    >
    > In other words, you'll get no better answer today than you did
    >
    > three days ago unless you explain your situation more clearly.
    >
    >
    >
    > --
    >
    > Eric Sosman
    >
    > d


    I think he wants to do what's called a Toast.

    http://en.wikipedia.org/wiki/Toast_(computing)
    bob smith, Oct 19, 2012
    #4
  5. K

    Lew Guest

    bob smith wrote:
    >Eric Sosman wrote:
    >> K wrote:
    >>> Does anyone know how to make certain text in a java application delay and display after the previous text

    >
    >> System.out.println("the previous text");
    >> try {
    >> Thread.sleep(desired_delay_in_milliseconds);
    >> } catch (InterruptedException ex) {
    >> System.out.println("This may be premature, but:");
    >> }
    >> System.out.println("certain text");

    >
    >> In other words, you'll get no better answer today than you did
    >> three days ago unless you explain your situation more clearly.

    >
    > I think he wants to do what's called a Toast.
    >
    > http://en.wikipedia.org/wiki/Toast_(computing)


    Maybe, but he insisted that he's talking about lines of text, so probably not.

    It's not clear, and given that he already asked this question and got advice, and
    opened up a new thread and provided no further clarification or elaboration,
    one wonders if it's even worth the bother to address the question.

    --
    Lew
    Lew, Oct 20, 2012
    #5
  6. K

    Rajiv Gupta Guest

    On 2012-10-20 04:15:27 +1100, K said:

    > Does anyone know how to make certain text in a java application delay
    > and display after the previous text


    There is always a delay after displaying text. This delay is provided
    free of charge to you by the inherent latency in the JVM and the
    operating system.
    Rajiv Gupta, Oct 20, 2012
    #6
  7. K

    Roedy Green Guest

    On Fri, 19 Oct 2012 10:15:27 -0700 (PDT), K <> wrote,
    quoted or indirectly quoted someone who said :

    >Does anyone know how to make certain text in a java application delay and display after the previous text


    you would create a timer that did a setText with different text on
    each trigger.

    See the code for SetClock. It updates the time periodically.

    See http://mindprod.com/webstart/setclock.html
    --
    Roedy Green Canadian Mind Products http://mindprod.com
    There are four possible ways to poke a card into a slot.
    Nearly always, only one way works. To me that betrays a
    Fascist mentality, demanding customers conform to some
    arbitrary rule, and hassling them to discover the magic
    orientation. The polite way to do it is to design the reader
    slot so that all four ways work, or so that all the customer
    has to do is put the card in the vicinity of the reader.
    Roedy Green, Oct 21, 2012
    #7
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Ingmar Seifert

    Delay of control signals

    Ingmar Seifert, Aug 18, 2003, in forum: VHDL
    Replies:
    0
    Views:
    1,181
    Ingmar Seifert
    Aug 18, 2003
  2. john
    Replies:
    1
    Views:
    564
    Kai Harrekilde-Petersen
    Aug 28, 2003
  3. Kelvin
    Replies:
    0
    Views:
    926
    Kelvin
    Sep 14, 2003
  4. Replies:
    6
    Views:
    759
    Andrew Thompson
    Jul 29, 2006
  5. leo
    Replies:
    1
    Views:
    254
    Bob Lehmann
    Dec 5, 2005
Loading...

Share This Page