ActivityLog.TryLogError(String, String) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Logs an error message in the activity log with the given source.
public:
static bool TryLogError(System::String ^ source, System::String ^ message);
public:
static bool TryLogError(Platform::String ^ source, Platform::String ^ message);
static bool TryLogError(std::wstring const & source, std::wstring const & message);
public static bool TryLogError (string source, string message);
static member TryLogError : string * string -> bool
Public Shared Function TryLogError (source As String, message As String) As Boolean
Parameters
- source
- String
A name associated with the source contributing the message.
- message
- String
The message to be written to the activity log.
Returns
True if the logging operation succeeded. False otherwise.