log4net for Windows Forms, log4net and ELMAH for ASP.NET.
ELMAH and log4net have different purposes. ELMAH captures data regarding unhandled exceptions whereas log4net provides a logging framework at configurable levels (INFO, WARN, DEBUG, FATAL). log4net requires that you actively write logging statements in your code; ELMAH works automatically once properly configured.