共用方式為


AnnotationResource 建構函式

定義

初始化 AnnotationResource 類別的新執行個體。

多載

名稱 Description
AnnotationResource()

此建構器支援 Windows Presentation Foundation 基礎架構,並非直接從您的程式碼中使用。

AnnotationResource(Guid)

此建構器支援 Windows Presentation Foundation 基礎架構,並非直接從您的程式碼中使用。

AnnotationResource(String)

初始化一個以指定名稱的 AnnotationResource 類別新實例。

AnnotationResource()

此建構器支援 Windows Presentation Foundation 基礎架構,並非直接從您的程式碼中使用。

public:
 AnnotationResource();
public AnnotationResource();
Public Sub New ()

備註

此建構器僅用於註解序列化器。 針對應用程式需求,使用 AnnotationResource 接受指定 name 參數的建構子。

適用於

AnnotationResource(Guid)

此建構器支援 Windows Presentation Foundation 基礎架構,並非直接從您的程式碼中使用。

public:
 AnnotationResource(Guid id);
public AnnotationResource(Guid id);
new System.Windows.Annotations.AnnotationResource : Guid -> System.Windows.Annotations.AnnotationResource
Public Sub New (id As Guid)

參數

id
Guid

全球唯一識別碼(GUID)用來識別此資源。

例外狀況

id 等於 Guid。空。

備註

此建構器僅用於註解序列化器。 針對應用程式需求,使用 AnnotationResource 接受指定 name 參數的建構子。

適用於

AnnotationResource(String)

初始化一個以指定名稱的 AnnotationResource 類別新實例。

public:
 AnnotationResource(System::String ^ name);
public AnnotationResource(string name);
new System.Windows.Annotations.AnnotationResource : string -> System.Windows.Annotations.AnnotationResource
Public Sub New (name As String)

參數

name
String

一個用來區分此資源與其他 Anchors 資源並 Cargos 在同一註解中定義的名稱。

例外狀況

namenull

備註

name該參數僅為方便而提供,且不會對字串進行驗證。

建構子會 AnnotationResource 自動建立一個可透過 Id 屬性存取的 GUID。

適用於