Share via


desktop10:CustomEventSource

Description

定義自訂事件記錄檔內的事件來源。

元素階層

<套件>

    <擴充功能>

         <desktop10:Extension>

              <desktop10:CustomDesktopEventLog>

                   <desktop10:CustomEventSource>

Syntax

<desktop10:CustomEventSource
  EventSourceName = 'A string with a value between 1 and 32767 characters in length that cannot start or end with a whitespace character. May contain whitespace characters in between the first and last values.'
  CategoryCount = 'An optional unsigned integer value. A number between -2147483648 and 2147483647.'
  CategoryMessageFile = 'A string with a value between 1 and 256 characters in length and cannot contain these characters: <, >, :, ", |, ?, or *.'
  >

  <!-- Child Elements -->
  desktop10:CustomEventSource
  desktop10:TypesSupported

</desktop10:CustomEventSource>

屬性和元素

屬性

屬性 描述 資料類型 必要 預設值
EventSourceName 自訂事件來源的名稱。 用來作為登錄機碼名稱。 長度介於 1 到 32767 個字元之間的字串,不能以空白字元開頭或結尾。 可能包含介於第一個和最後一個值之間的空白字元。 Yes
CategoryCount 支援的事件類別目錄數目。 選擇性不帶正負號的整數值。 -2147483648 與 2147483647 之間的數位。 No
CategoryMessageFile 類別訊息檔案的路徑。 類別訊息檔案包含描述類別的語言相依字串。 長度介於 1 到 256 個字元之間的字串,不能包含下列字元: < 、、 ":|>? 或 。 * No

子元素

子項目 描述
desktop10:EventMessageFiles 定義包含描述事件之語言字串的 1 或多個 DLL 檔案。
desktop10:TypesSupported 定義事件來源支援的 1 或多個事件記錄檔類型。

父元素

父元素 描述
desktop10:CustomDesktopEventLog 宣告應用程式的擴充點。

備註

如需自訂事件來源的詳細資訊,請參閱 事件來源

規格需求

Item
desktop10 http://schemas.microsoft.com/appx/manifest/desktop/windows10/10
OS 最低版本 Windows 11版本 22H2 (組建 22621)