Equivalent implementation for <customErrors mode=RemoteOnly /> behaviour
<p>From <a href="http://msdn.microsoft.com/en-us/library/h0hfz6fc.aspx" rel="nofollow">msdn</a> site, I know that <strong>customErrors</strong> element provides information about custom error messages for an ASP.NET application. <strong>RemoteOnly</strong> value for <strong>mode</strong> attribute specifies that custom errors are shown only to the <em>remote clients</em>, and that ASP.NET errors are shown to the <em>local host</em>. </p>

<p>At c# side, how can it be implemented, that some logic invokes only for remote clients, and other for local host (c# code which check this condition will be invoked from Global.asax.cs Application_Error level) ?</p>
