The options for error reports presented above are certainly valuable for the everyday use. But what about the development period? Here, AFP provides a ready-to-use error page for development with all the details you require. You can activate this option in afp.config under config/afp/debug/show-error. You can also modify this behavior during runtime. With the help of the following code in event PageCall you can ensure that the detailed report will display exclusively to you whereas all other users will see the pre-configured error messages.
Procedure Event_PageCall
If Lower(Request.ServerVariables("HOST_NAME")) == "localhost"
Error.lShowError = .T.
Else
Error.lShowError = .F.
EndIf
EndProc
The illustration below shows this in detail. We do not recommend offering a detailed error message like this on a production system to the public. By giving away too many details about your system and its configuration including data about paths and system variables you would probably achieve the opposite of what you intended.
