This is a very basic question but how do i only allow numberic values in my if statement? For example if user inputs string as an id it should give an error saying only numeric value allowed.
Console.Write("Please enter your ID: ");
int id = Int32.Parse(Console.ReadLine());
if () // what should I write here?
{
Console.WriteLine("Only Numeric value are allowed.");
}else{
Console.WriteLine("My ID is {0}", id);}