Hello @Brijendra Gautam ,
Welcome to Microsoft Q&A forum.
I’m afraid, as VS 2019 doesn’t support .NET 6 and .NET 7, it’s not possible to create .NET 6/.NET 7 based projects in VS 2019(see this document: Visual Studio 2019 Support for .NET Development). You need to use VS 2022 for full .NET 6/.NET 7 support.
The "Use previews of the .NET SDK" option doesn’t work in this situation.
Some related blog and thread:
Visual Studio 2019 support .NET 6
Projects based on earlier versions of .NET Core may still be able to be created in VS 2019. But as earlier versions of .NET Core reached EOL, it is recommended to use VS 2022 and higher version of .NET.
Best Regards,
Tianyu
- If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.