views:

142

answers:

1

hi in my application i have 20 icons(bitmap fields) on the home screen When i click on any icon an HTTP request is made in a separate thread.

I have used invoke later method wherever necessary to take care of multi-threading problems.

But still the number of threads goes beyond 16 and an error pops up indicating too many threads error and applications needs to be restarted!!

can anybody tell me how to destroy these threads when they are no longer in use. I don't understand why they don't destroy on their own as usually they do.

A: 
I tried to go ahead with active count of thread
If that count exceeds beyond the limit set by me then i queue up the request 

and then send them later on after sometime.

but this delays the response.

I had no other option other than this

Thanks for help!!!!!!!
SWATI