Naughter Software Logo

PStat v1.25 A generalized framework for executing a lengthy operation in a thread.

For developers who use MFC, this is a module which provides a single easy to use function which allows one of your functions to be executed in a separate thread. Feedback is provided by a progress dialog which can optionally be cancelled. The sample application included with PStat allows you to calculate the 1,000,000th prime number both with and without PStat. Try using the "without PStat" option from the test program and tab to another program, when you tab back you will notice that it's window is not redrawn because it is not responding to any window messages. Now try the same with PStat, Notice the difference!

When executed with PStat, while your function is being executed a progress dialog will be displayed as:

PStat screen capture 1

If you want to allow the user to cancel the operation during your function then the progress dialog can be displayed with a cancel button as:

PStat screen capture 2


The function PStat provides allows a number of values to be modified, these include the caption to use on the progress dialog and the priority to use when executing the thread. The enclosed zip file contains source for the routine and also includes a VC 2010 workspace file to build a small dialog based app which calculates the 1,000,000th prime number both with and without PStat.





v1.25 (21 January 2017)

v1.24 (23 July 2007)

v1.23 (3 February 2003)

v1.22 (31 March 2000)

v1.21 (28 March 2000)

v1.2 (8 November 1998)

v1.1 (18 February 1998)

v1.0 (27 March 1997)