using System.Collections.Generic;
public static void Main()
var innerEx = new List<Exception>();
var test = new AggregateException(innerEx);
Console.WriteLine(test.ToString());
public static void TestMethod(int i)
throw new ArgumentException(i.ToString());
throw new Exception("See innerException",ex);
public static void TestSubMethod(int i)
throw new Exception(i.ToString());