in reply to multithreading sample

Here's a somewhat longer example/tutorial: Going Up?.

However you may not need multithreading, care to explain more what you want to do?

C.