Re: [android-developers] Re: android loop problem

2011-07-07 Thread wu mark
But It doesn't display the screen that I display in the loop. I don't think
it had executed the loop part.

Mark

2011/7/6 saurabh chatterjee chattsaur...@gmail.com

 may be your code is getting entangled in an infinite loop. have you
 tried using break ?

 On Jul 6, 4:51 pm, mark2011 androidmark2...@gmail.com wrote:
  Dear All :
 
 I met a strange event. I write a simple code to display a screen
  once the user click a button to start. In the screen, the user can
  click some button to set up the factors that I use onclicklistener to
  accept the onclick. But the start button is that I use onclick to
  start. Once I use a loop using the for/while command to loop the
  display the screen. The start button doesn't work. Can anyone help me?
 
  Thanks.
 
  BR,
  mark

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


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

Re: [android-developers] Re: android loop problem

2011-07-07 Thread Kostya Vasilyev
Based on what you've explained so far, I think you are running your loop 
on the main (UI) thread, and are thus blocking it from doing anything 
else, which includes updating the UI.


Have you read this:

http://developer.android.com/guide/topics/fundamentals/processes-and-threads.html#Threads

http://developer.android.com/resources/articles/painless-threading.html

-- Kostya

07.07.2011 12:12, wu mark ?:
But It doesn't display the screen that I display in the loop. I don't 
think it had executed the loop part.

Mark

2011/7/6 saurabh chatterjee chattsaur...@gmail.com 
mailto:chattsaur...@gmail.com


may be your code is getting entangled in an infinite loop. have you
tried using break ?

On Jul 6, 4:51 pm, mark2011 androidmark2...@gmail.com
mailto:androidmark2...@gmail.com wrote:
 Dear All :

I met a strange event. I write a simple code to display a screen
 once the user click a button to start. In the screen, the user can
 click some button to set up the factors that I use
onclicklistener to
 accept the onclick. But the start button is that I use onclick to
 start. Once I use a loop using the for/while command to loop the
 display the screen. The start button doesn't work. Can anyone
help me?

 Thanks.

 BR,
 mark

--
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to
android-developers@googlegroups.com
mailto:android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
mailto:android-developers%2bunsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en


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


--
Kostya Vasilyev

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

[android-developers] Re: android loop problem

2011-07-06 Thread saurabh chatterjee
may be your code is getting entangled in an infinite loop. have you
tried using break ?

On Jul 6, 4:51 pm, mark2011 androidmark2...@gmail.com wrote:
 Dear All :

    I met a strange event. I write a simple code to display a screen
 once the user click a button to start. In the screen, the user can
 click some button to set up the factors that I use onclicklistener to
 accept the onclick. But the start button is that I use onclick to
 start. Once I use a loop using the for/while command to loop the
 display the screen. The start button doesn't work. Can anyone help me?

 Thanks.

 BR,
 mark

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