Skip to content

Add Warning in WindowsDesktop SDK for UseWinForms  #1226

@vatsan-madhavan

Description

@vatsan-madhavan

See dotnet/wpf#1027 (comment)

The comment from @drewnoakes suggests that there is occasional confusion that leads to the use of UseWinForms in Microsoft.NET.Sdk.WindowsDesktop based projects instead of using the correct property UseWindowsForms.

The current behavior will be warning NETSDK1106 ("Windows Desktop SDK requires UseWpf or UseWindowsForms"). This should help the vast majority of WinForms projects that guess the property name wrong.

The small number of projects that try to set UseWpf and UseWinForms (instead of the correct property UseWindowsForms) will not receive any warnings today.

We should evaluate whether a new warning is needed to help those who set UseWinForms and add it to the WindowsDesktop SDK.

/cc @merriemcgaw, @OliaG

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions