How to pass command line arguments in Visual Studio 2022?
How to pass command line arguments in Visual Studio 2022?
Right-click Projects -> Properties
In the window select Debug -> General -> Open debug launch profiles UI
How to access the command line variables when top-level statements is used?
Console.WriteLine("Hello, World!");
foreach(var s in args)
{
Console.Write($"{s}, ");
}
For more information about top-level statements follow this url:
https://learn.microsoft.com/en-us/dotnet/csharp/whats-new/tutorials/top-level-statements
Comments
Post a Comment