Β© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
C#C
C#β€’9mo agoβ€’
4 replies
LPeter1997

CsWin32 not generating CreateSemaphoreA

I'm using CsWin32 to generate PInvokes for win32 methods. When I specify
CreateSemaphore
CreateSemaphore
(with or without the suffix, doesn't matter), it does not generate
CreateSemaphoreA
CreateSemaphoreA
, only
CreateSemaphoreW
CreateSemaphoreW
. I have a
NativeMethods.json
NativeMethods.json
created in the project root next to
NativeMethods.txt
NativeMethods.txt
:
{
  "$schema": "https://aka.ms/CsWin32.schema.json",
  "wideCharOnly": false
}
{
  "$schema": "https://aka.ms/CsWin32.schema.json",
  "wideCharOnly": false
}
C# banner
C#Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

βœ… CsWin32 not generating PInvoke for GetThreadContext
C#CC# / help
9mo ago
βœ… CoTaskMemFree on a buffer returned by CsWin32
C#CC# / help
3y ago
Using CsWinRT not generating files?
C#CC# / help
5mo ago
❔ protobuf not generating proto files
C#CC# / help
4y ago