Win32Net 1.0.1

There is a newer version of this package available.
See the version list below for details.
dotnet add package Win32Net --version 1.0.1
NuGet\Install-Package Win32Net -Version 1.0.1
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Win32Net" Version="1.0.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Win32Net --version 1.0.1
#r "nuget: Win32Net, 1.0.1"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Win32Net as a Cake Addin
#addin nuget:?package=Win32Net&version=1.0.1

// Install Win32Net as a Cake Tool
#tool nuget:?package=Win32Net&version=1.0.1

介绍

Win32API的.NET下封装,包含 1: 常用win32的API的net封装 2:鼠标、键盘、热键hook钩子模块, 3:模拟键盘输入文字(支持各种字符文字、不同语言的文字)、模拟鼠标点击移动滚动等操作 4:延迟函数Delay方法

版本更新

v1.0.1

添加net40;net45;net48,暂时移除net6框架

安装教程

  1. Nuget搜索win32net,安装即可

使用说明

Win32命名空间下包含各种常用api,如:win32.User32.GetDesktopWindow()//获取桌面窗口句柄;

Win32.Hooks,命名空间下包含鼠标键盘热荐的钩子相关类。 例如鼠标钩子: Win32.Hooks.MouseHook mouseHook = new Hooks.MouseHook();//实例化鼠标钩子对象

mouseHook.LeftDown += MouseHook_LeftDown;//鼠标左键按下的事件监听回调方法

mouseHook.Start();//开始监听

mouseHook.Stop();//停止监听

Win32.Input.Keyboard.KeyDown(System.Windows.Forms.Keys.Enter);//按回车键

Win32.Input.Mouse.LeftClick(150, 100);//鼠标左键单击

Win32.Input.Wait.Delay(1500);//延迟1500毫秒

Win32.Input.Keyboard.Type("输入文字1234abc");//模拟输入文字,支持各种语言文字字符

Product Compatible and additional computed target framework versions.
.NET net5.0-windows7.0 is compatible.  net6.0-windows was computed.  net7.0-windows was computed.  net8.0-windows was computed. 
.NET Framework net40 is compatible.  net403 was computed.  net45 is compatible.  net451 was computed.  net452 was computed.  net46 was computed.  net461 is compatible.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 is compatible.  net481 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • .NETFramework 4.0

    • No dependencies.
  • .NETFramework 4.5

    • No dependencies.
  • .NETFramework 4.6.1

    • No dependencies.
  • .NETFramework 4.8

    • No dependencies.
  • net5.0-windows7.0

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Win32Net:

Package Downloads
YancheeGame

Package Description

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.4.0 181 3/6/2024
1.3.0 905 11/25/2022
1.2.0 1,022 12/11/2021
1.0.1 2,756 11/25/2021
1.0.0 1,167 11/21/2021