0

I need to use a dialog. That appears 2-3 seconds and after closes automatically. Which object should I use On BlackBerry?

Cœur
  • 37,241
  • 25
  • 195
  • 267
atasoyh
  • 3,045
  • 6
  • 31
  • 57

2 Answers2

2

you can also use

Status.show(String message) 

Shows a status screen for two seconds.

or

Status.show(String message, Bitmap bitmap, int time) 

Shows a status screen with specified icon, for specified time.

Vivart
  • 14,900
  • 6
  • 36
  • 74
1

Create a class that extends PopupScreen and use a TimerTask to automatically close it. So you would have code in your constructor that looks sort of like this:

    Timer timer = new Timer();
    timer.schedule(new TimerTask(){

        public void run()
        {
            if(TestScreen.this.isDisplayed())
            {
                synchronized (Application.getEventLock())
                {
                    TestScreen.this.close();
                }
            }
        }

    }, WAIT_TIME_IN_MILLISECONDS);
Jonathan
  • 1,735
  • 11
  • 17