Click here to Skip to main content
11,789,710 members (62,419 online)
Rate this: bad
Please Sign up or sign in to vote.
See more: C++ C Threading
I am new to thread pools and well I wanted to start of by creating and destroying a thread pool first,I assume that's how we create a thread pool:

PTP_POOL Pool = CreateThreadpool(NULL);
cout<<"Pool Created"<<endl;

the code builds fine,however when I run it,I get the following pop up message:

The procedure entry point Create Threadpool could not be located in the dynamic link library KRENEL32.dll
Posted 18-Apr-13 23:49pm
CPallini at 19-Apr-13 6:10am
Does your system satisfy minimum requirements (Windows Vista)?
Aayman Khalid at 19-Apr-13 6:23am
no it's xp:(
Philippe Mori at 19-Apr-13 18:40pm
You should always read MSDN documentation for a function that you don't know and pay attention to its requirements.

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

As CPallini has pointed out this API requires Windows Vista at runtime and a _WIN32_WINNT >= 0x0600 at compile time in order to use it.

There are plenty of other C++ Thread Pool implementations which work very well on Windows and existed before Microsoft chose to expose an API to their own. Try searching Code Project for 'Thread Pool' and you'll see.
Aayman Khalid at 19-Apr-13 7:35am
Alright,Thank you...
CPallini at 19-Apr-13 7:56am

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 999
1 Maciej Los 765
2 KrunalRohit 686
3 CPallini 606
4 Richard MacCutchan 430

Advertise | Privacy | Mobile
Web04 | 2.8.1509028.1 | Last Updated 19 Apr 2013
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100