Open aadog opened 3 weeks ago
@aadog I cannot reproduce this issue in my machine with same .NET 9.0 version:
@Olina-Zhang *.csproj add `
`
@Olina-Zhang like he
Trimming/AOTing WinForms Apps is not supported at this time. When setting it, the form designer cannot be loaded successfully. Related issue: https://github.com/dotnet/winforms/issues/10741.
This is on our radar but there is not a specific schedule to get this working. It is expected that you will get trim warnings with data binding and we need to redesign how databinding and trimming work.
What options do we have to not crop parts
.NET version
.NET SDK: Version: 9.0.100-rc.2.24474.11 Commit: 315e1305db Workload version: 9.0.100-manifests.4872d5d5 MSBuild version: 17.12.0-preview-24473-03+fea15fbd1
运行时环境: OS Name: Windows OS Version: 10.0.22631 OS Platform: Windows RID: win-x64 Base Path: C:\Program Files\dotnet\sdk\9.0.100-rc.2.24474.11\
Did it work in .NET Framework?
Yes
Did it work in any of the earlier releases of .NET Core or .NET 5+?
net 8
Issue description
build to winform aot mode ,Binding operations are not supported when application clipping is enabled
System.NotSupportedException:“启用应用程序剪裁时不支持绑定操作。”
Steps to reproduce
`
<_SuppressWinFormsTrimError>true`
` textBox1.DataBindings.Add("Text", button1, "Text");
`