共用方式為


WebPart.EffectiveTitle property

取得標題指定網頁組件的執行個體,包括新增網頁組件基礎結構的任何去除混淆資訊。

Namespace:  Microsoft.SharePoint.WebPartPages
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'宣告
Public ReadOnly Property EffectiveTitle As String
    Get
'用途
Dim instance As WebPart
Dim value As String

value = instance.EffectiveTitle
public string EffectiveTitle { get; }

Property value

Type: System.String
包含網頁組件,包括任何去除混淆資訊,例如"網頁組件 [1]"及"網頁組件 [2]"的標題string 。

備註

如果在相同的網頁組件] 頁面上的兩個網頁組件有相同的標題,網頁組件基礎結構,將數字附加之後標題。例如,如果名為MyWebPart的兩個或多個網頁組件新增至頁面,網頁組件基礎結構新增遞增的號碼以下列格式: MyWebPart [1][2] MyWebPart,等等。您可以使用EffectiveTitle屬性擷取包含此遞增的數字的網頁組件的標題。

請參閱

參照

WebPart class

WebPart members

Microsoft.SharePoint.WebPartPages namespace