a. In Windows Explorer, navigate to the Inetpub directory (typically C:\inetpub), and then navigate to \adfs\ls\ b. Open web.config in a text editor c. Locate the following lines: <!-- <add key="displayExceptions" /> --> d. Uncomment the displayExceptions key like this: <add key="displayExceptions" /> e. Save and close web.config 2. Modify error.aspx.cs to show more exception detail Note: You can see all possible exception properties here. a. In Windows Explorer, navigate to the Inetpub directory (typically C:\inetpub) and then navigate to \adfs\ls\ b. Open error.aspx.cs in a text editor c. Locate the following line: ExceptionMessageLabel.Text = Exception != null ? Exception.Message : String.Empty; d. Modify the line from step c to include additional Exception properties. For readability, the example below is concatenating strings by using a " - " separator: ExceptionMessageLabel.Text = Exception != null ? Exception.HResult + " - " + Exception.InnerException + " - " + Exception.Message + " - " + Exception.StackTrace : String.Empty; e. Save and close error.aspx.cs 3. Test by reproducing an error page. AD FS will now show exceptions on the error page, and will include the Exception properties you defined in step 2. d.
a. In Windows Explorer, navigate to the Inetpub directory (typically C:\inetpub), and then navigate to \adfs\ls\ b. Open web.config in a text editor c. Locate the following lines: <!-- <add key="displayExceptions" /> --> d. Uncomment the displayExceptions key like this: <add key="displayExceptions" /> e. Save and close web.config
Note: You can see all possible exception properties here. a. In Windows Explorer, navigate to the Inetpub directory (typically C:\inetpub) and then navigate to \adfs\ls\ b. Open error.aspx.cs in a text editor c. Locate the following line: ExceptionMessageLabel.Text = Exception != null ? Exception.Message : String.Empty; d. Modify the line from step c to include additional Exception properties. For readability, the example below is concatenating strings by using a " - " separator: ExceptionMessageLabel.Text = Exception != null ? Exception.HResult + " - " + Exception.InnerException + " - " + Exception.Message + " - " + Exception.StackTrace : String.Empty; e. Save and close error.aspx.cs
Adam Conkle - MSFT edited Revision 1. Comment: Finished editing.