Why not use the
args
parameter of your
Main
method? That is exactly what it is there for...
"able to show me some example, becourse i am not good in console app and batch file also"
Batch file:
myAppName ParameterText MoreParameters
Your app:
static void Main(string[] args)
{
foreach (string arg in args)
{
Console.WriteLine(arg);
}
}
Output:
ParameterText
MoreParameters