What DLL is processthreadsapi/GetCurrentProcessId located in?

Todd Chester 636 Reputation points
2022-11-18T10:06:39.543+00:00

Hi All,

I am trying to make from Raku a call to

GetCurrentProcessId function (processthreadsapi.h)

https://learn.microsoft.com/en-us/windows/win32/api/processthreadsapi/nf-processthreadsapi-getcurrentprocessid

Raku's compiler does not liek

sub GetCurrentProcessId()
is native("processthreadsapi")
is symbol("GetCurrentProcessId")
returns DWORD
{ * };

It can't find "processthreadsapi.dll".

What dll is GetCurrentProcessId located in?

Many thanks,
-T

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,072 questions
{count} votes

Accepted answer
  1. RLWA32 32,156 Reputation points
    2022-11-18T10:08:47.317+00:00

    The answer to your question is stated right in the documentation for which you posted a link. Look towards the bottom of the page and it will tell you that the function is located in kernel32.dll.

    0 comments No comments

0 additional answers

Sort by: Most helpful