Skip to content

A source generator to add a user-defined set of Win32 P/Invoke methods and supporting types to a C# project.

License

Notifications You must be signed in to change notification settings

microsoft/CsWin32

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Mar 10, 2025
10ff614 · Mar 10, 2025
Jun 7, 2023
Feb 27, 2025
Feb 12, 2025
Mar 7, 2025
Mar 4, 2024
Mar 7, 2025
Mar 8, 2025
Feb 8, 2025
Mar 10, 2025
Mar 8, 2025
Feb 7, 2025
Sep 9, 2024
Feb 16, 2023
Oct 11, 2024
Feb 9, 2024
Dec 1, 2020
Feb 7, 2025
Jun 23, 2023
Jan 16, 2025
Mar 3, 2020
Jan 7, 2025
Feb 8, 2025
Mar 8, 2025
Oct 26, 2020
May 25, 2023
May 6, 2021
Jan 16, 2025
Sep 6, 2022
Sep 2, 2022
Jan 16, 2025
Aug 15, 2024
Feb 21, 2025
Aug 19, 2020
Jan 7, 2025
Sep 2, 2022
Nov 22, 2023
May 6, 2022
May 9, 2024

Repository files navigation

C#/Win32 P/Invoke Source Generator

A source generator to add a user-defined set of Win32 P/Invoke methods and supporting types to a C# project.

NuGet (prerelease) NuGet (daily)

Build Status

Features

  • Rapidly add P/Invoke methods and supporting types to your C# project.
  • No bulky assemblies to ship alongside your application.
  • SafeHandle-types automatically generated.
  • Generates xml documentation based on and links back to docs.microsoft.com

Animation demonstrating p/invoke code generation

Usage

Check out our product documentation.