Thanks you two... This forum has been a biig help. I see your names
all over the place here. Thank you very much. I believe Mark even
helped me with the last problem I got stuck on.

I ended up doing this:
Random rn = new Random();
        long range = 6;
        long fraction = (long) (range*rn.nextDouble());
        int randomNumber = (int)(fraction)*1000+5100;
        pgs.playSound(1);
        Handler pgsHandler = new Handler();
        pgsHandler.postDelayed(new Runnable() {
            public void run() {
                pgs.playSound(2);
            }
        }, randomNumber);

Do I have to make a handler? Or can I use the postDelayed of the
button?



On Mar 30, 6:09 pm, BiiG <[email protected]> wrote:
> Thanks. I found it... now to figure out Runnable.
>
> On Mar 30, 6:04 pm, Mark Murphy <[email protected]> wrote:
>
>
>
> > BiiG wrote:
> > > Having trouble with the postDelayed(). My eclipse isn't recognizing it
> > > and for some reason I can't get on tohttp://developer.android.com/to
> > > investigate.
>
> > It is a method on View (in other words, every widget and container) and
> > on Handler.
>
> > --
> > Mark Murphy (a Commons 
> > Guy)http://commonsware.com|http://twitter.com/commonsguy
>
> > _The Busy Coder's Guide to Android Development_ Version 3.0
> > Available!- Hide quoted text -
>
> - Show quoted text -

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

To unsubscribe, reply using "remove me" as the subject.

Reply via email to