March 2004
Intermediate to advanced
560 pages
26h 47m
English
using System;
namespace Samples
{
class ArgumentNullExceptionSample
{
public static void Main()
{
String[] strings = null;
String separator = " ";
try
{
String s = String.Join(separator, strings);
}
catch(ArgumentNullException e)
{
Console.WriteLine("Exception: {0}", e);
}
}
}
}
Exception: System.ArgumentNullException: Value cannot be null. Parameter name: value at System.String.Join(String separator, String[] value) at Samples.ArgumentNullExceptionSample.Main() in C:\Books\BCL\Samples\System\ ArgumentNullException\ArgumentNullException.cs:line 13
Read now
Unlock full access