![]() |
VOOZH | about |
dotnet add package WinFormsComInterop --version 0.5.0
NuGet\Install-Package WinFormsComInterop -Version 0.5.0
<PackageReference Include="WinFormsComInterop" Version="0.5.0" />
<PackageVersion Include="WinFormsComInterop" Version="0.5.0" />Directory.Packages.props
<PackageReference Include="WinFormsComInterop" />Project file
paket add WinFormsComInterop --version 0.5.0
#r "nuget: WinFormsComInterop, 0.5.0"
#:package WinFormsComInterop@0.5.0
#addin nuget:?package=WinFormsComInterop&version=0.5.0Install as a Cake Addin
#tool nuget:?package=WinFormsComInterop&version=0.5.0Install as a Cake Tool
This repository has ComWrappers implementation for WinForms. In additional to that, it allow use WinForms and NativeAOT and R2R with trimming together.
Just add WinFormsComInterop to your project.
dotnet add package WinFormsComInterop
Then to your Program.cs add following line
ComWrappers.RegisterForMarshalling(WinFormsComInterop.WinFormsComWrappers.Instance);
And modify project file to enable NativeAOT
<PublishAot>true</PublishAot>
<_SuppressWinFormsTrimError>true</_SuppressWinFormsTrimError>
If you application will works with this ComWrappers implementation, then most likely it would work with NativeAOT.
If you are using WebView2 using Microsoft.Web.WebView2.Core package, then use
ComWrappers.RegisterForMarshalling(WinFormsComInterop.WebView2.WebView2ComWrapper.Instance);
Also
<PackageReference Include="Microsoft.Web.WebView2" Version="1.0.1462.37" /> as depedency. This library would work only starting from this version of WebView2 package.<RdXmlFile Include="Microsoft.AspNetCore.Components.Web.rd.xml" /> to project file<?xml version="1.0" encoding="utf-8" ?>
<Directives>
<Application>
<Assembly Name="YourAppAssembly" Dynamic="Required All">
<Type Name="YourAppAssembly.YourRootComponent" Dynamic="Required All" />
</Assembly>
</Application>
</Directives>
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net6.0 net6.0 is compatible. net6.0-android net6.0-android was computed. net6.0-ios net6.0-ios was computed. net6.0-maccatalyst net6.0-maccatalyst was computed. net6.0-macos net6.0-macos was computed. net6.0-tvos net6.0-tvos was computed. net6.0-windows net6.0-windows was computed. net7.0 net7.0 is compatible. net7.0-android net7.0-android was computed. net7.0-ios net7.0-ios was computed. net7.0-maccatalyst net7.0-maccatalyst was computed. net7.0-macos net7.0-macos was computed. net7.0-tvos net7.0-tvos was computed. net7.0-windows net7.0-windows was computed. net8.0 net8.0 is compatible. net8.0-android net8.0-android was computed. net8.0-browser net8.0-browser was computed. net8.0-ios net8.0-ios was computed. net8.0-maccatalyst net8.0-maccatalyst was computed. net8.0-macos net8.0-macos was computed. net8.0-tvos net8.0-tvos was computed. net8.0-windows net8.0-windows was computed. net9.0 net9.0 was computed. net9.0-android net9.0-android was computed. net9.0-browser net9.0-browser was computed. net9.0-ios net9.0-ios was computed. net9.0-maccatalyst net9.0-maccatalyst was computed. net9.0-macos net9.0-macos was computed. net9.0-tvos net9.0-tvos was computed. net9.0-windows net9.0-windows was computed. net10.0 net10.0 was computed. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
Showing the top 1 NuGet packages that depend on WinFormsComInterop:
| Package | Downloads |
|---|---|
|
WenAntdUI
Package Description |
Showing the top 2 popular GitHub repositories that depend on WinFormsComInterop:
| Repository | Stars |
|---|---|
|
AntdUI/AntdUI
👚 Winform interface library based on the Ant Design
|
|
|
lindexi/lindexi_gd
博客用到的代码
|
| Version | Downloads | Last Updated |
|---|---|---|
| 0.5.0 | 53,660 | 6/16/2024 |
| 0.4.3 | 5,109 | 1/18/2023 |
| 0.4.2 | 644 | 12/23/2022 |
| 0.4.1 | 508 | 12/23/2022 |
| 0.4.0 | 510 | 12/23/2022 |
| 0.3.2 | 2,879 | 10/23/2022 |
| 0.3.1 | 591 | 10/23/2022 |
| 0.3.0 | 660 | 9/3/2022 |
| 0.2.9 | 943 | 7/21/2021 |
| 0.2.8 | 660 | 7/15/2021 |
| 0.2.7 | 526 | 7/11/2021 |
| 0.2.6 | 521 | 6/17/2021 |
| 0.2.5 | 538 | 6/15/2021 |
| 0.2.4 | 553 | 6/11/2021 |
| 0.2.3 | 544 | 6/9/2021 |
| 0.2.2 | 536 | 6/4/2021 |
| 0.2.1 | 560 | 6/4/2021 |
| 0.2.0 | 578 | 6/3/2021 |
| 0.1.0 | 625 | 5/29/2021 |