I'm working on some MFC application which launches some quite complicated algorithm, which has many inside iterations and loops.
So , when user presses "Run Algorithm" button entire applications like "stuckes" until the algorithm finishes it's job. So, I would like to let user stop this algorithm in the middle by pressing some button. How am I implementing it? Maybe multithreads?