Share via


IWMSLoggingAdmin.Dirty (C#)

banner art

Previous Next

IWMSLoggingAdmin.Dirty (C#)

The Dirty property retrieves a Boolean value indicating whether the currently running configuration is different from the stored configuration.

Syntax

  bool =
  
  LoggingAdmin
  .Dirty;

Property Value

A bool indicating whether the currently running profile is different from the stored profile.

If this property fails, it throws an exception.

Number Description
0x80004005 The server cannot find the WMS Client Logging plug-in.

Remarks

If a property is modified while the plug-in is enabled, this flag is set to true. When this flag is set, the plug-in's currently running profile is different from the stored profile, and the changes will be applied when the plug-in is re-enabled. When a log is cycled or changes from disabled to enabled, the stored configuration is applied to the plug-in and this flag is cleared.

When this flag is TRUE, the plug-in's properties reflect the currently running instance of the plug-in. They do not reflect the stored configuration.

This property is read only.

Example Code

using Microsoft.WindowsMediaServices.Interop;
using System.Runtime.InteropServices;

// Declare variables.
WMSServer Server;
IWMSPlugin Plugin;
IWMSLoggingAdmin LogAdmin;

try {
    // Create a new WMSServer object.
    Server = new WMSServerClass();

    // Retrieve the plug-in to be configured.
    Plugin = Server.EventHandlers[
                        "WMS Client Logging"];

    // Retrieve the custom interface of the plug-in.
    LogAdmin =
        (IWMSLoggingAdmin)Plugin.CustomInterface;

    // Retrieve a Boolean value indicating
    // whether the log needs to be cycled
    // in order to use new configuration options.
    if(LogAdmin.Dirty == true)
        LogAdmin.CycleNow();
}
catch (COMException comExc) {
    // TODO: Handle COM exceptions.
}
catch (Exception e) {
    // TODO: Handle exceptions.
}

Requirements

Reference: Add a reference to Microsoft.WindowsMediaServices.

Namespace: Microsoft.WindowsMediaServices.Interop.

Assembly: Microsoft.WindowsMediaServices.dll.

Library: WMSServerTypeLib.dll.

Platform: Windows Server 2003 family, Windows Server 2008 family.

See Also

Previous Next