Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

c# get Full Exception message if InnerException is not NULL

public static string GetFullMessage(this Exception ex)
        {
            return ex.InnerException == null
                 ? ex.Message
                 : ex.Message + " --> " + ex.InnerException.GetFullMessage();
        }
 
PREVIOUS NEXT
Tagged: #Full #Exception #message #InnerException #NULL
ADD COMMENT
Topic
Name
5+5 =