According to this http://msdn.microsoft.com/en-us/library/ff512746.aspx I have to use this code WriteTrace(System.UInt32, Microsoft.SharePoint.Administration.SPDiagnosticsCategory, Microsoft.SharePoint.Administration.TraceSeverity, System.String, System.Object[]); WriteEvent(System.UInt16,Microsoft.SharePoint.Administration.SPDiagnosticsCategory,Microsoft.SharePoint.Administration.EventSeverity,System.String,System.Object[]);
However after adding that code and the using Microsoft.SharePoint.Administration; it generates compile time errors., as if those methods dont exist.
Please help