public static string InnerMessages(this Exception exception)
{
    var Ls = new List<string>();

    Ls.Add(exception.Message);
    while (exception.InnerException != null)
    {
        exception = exception.InnerException;
        Ls.Add(exception.Message);
    }

    return string.Join(" - ", Ls.ToArray());
}