I'm creating a java program that in every second there is a data stored into my table. I made use of THread.sleep(1000) to pause the for loop in every second.. But when my program runs, it freezed for 10 seconds because of the condition of my for loop where the counter has not yet reached 10. So my last choice was to use a Thread that will run on different process so as not to freeze the UI cause i've been doing this with .net.... But the big problem is I dont know how will the created thread will have access to the TABLE object which is at the Mainclass.
it2051229 -3 Junior Poster in Training
verruckt24 438 Posting Shark
neilcoffey 79 Junior Poster in Training
BestJewSinceJC 700 Posting Maven
Ezzaral 2,714 Posting Sage Team Colleague Featured Poster
neilcoffey 79 Junior Poster in Training
Ezzaral 2,714 Posting Sage Team Colleague Featured Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.