I am a newbie. when I run this program I get
"IndexOutOfRangeException was unhandled"
it points to this line
" System.Console.WriteLine(args[0]);"
can you help?
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication2
{
class Program
{
static void Main(string[] args)
{
System.Console.WriteLine(args[0]);
if (args[0] == "-help")
{
System.Console.WriteLine("you press help");
}
else if (args[0] == "-processor")
{
System.Console.WriteLine("you press processor");
}
}
}
}
"IndexOutOfRangeException was unhandled"
it points to this line
" System.Console.WriteLine(args[0]);"
can you help?
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace ConsoleApplication2
{
class Program
{
static void Main(string[] args)
{
System.Console.WriteLine(args[0]);
if (args[0] == "-help")
{
System.Console.WriteLine("you press help");
}
else if (args[0] == "-processor")
{
System.Console.WriteLine("you press processor");
}
}
}
}