public static string GetExecutableName(
bool includeExtension = false
)
Public Shared Function GetExecutableName (
Optional includeExtension As Boolean = false
) As String
Dim includeExtension As Boolean
Dim returnValue As String
returnValue = CommandLineParser.GetExecutableName(includeExtension)
public:
static String^ GetExecutableName(
bool includeExtension = false
)
To determine the executable name, this method first checks the EnvironmentProcessPath property (if using .Net 6.0 or later). If using the .Net Standard package, or if EnvironmentProcessPath returns "dotnet", it checks the first item in the array returned by EnvironmentGetCommandLineArgs, and finally falls back to the file name of the entry point assembly.
The return value of this function is used as the default executable name to show in the usage syntax when generating usage help, unless overridden by the UsageWriterExecutableName property.