共用方式為


VCCodeDelegate.Comment 屬性

取得或設定與此程式碼項目關聯的註解。

命名空間:  Microsoft.VisualStudio.VCCodeModel
組件:  Microsoft.VisualStudio.VCCodeModel (在 Microsoft.VisualStudio.VCCodeModel.dll 中)

語法

'宣告
Property Comment As String
string Comment { get; set; }
property String^ Comment {
    String^ get ();
    void set (String^ value);
}
abstract Comment : string with get, set
function get Comment () : String 
function set Comment (value : String)

屬性值

類型:String
與程式碼項目相關聯的註解。

備註

Comment 會設定或傳回標頭註解。 傳回時,這些文字並不包含任何註解語法。 註解文字係衍生自含有程式碼項目的來源文件。 標頭註解行數目收集的根據註解寫入的語言變更。

透過使用行導向式語法取代分隔式語法,設定時, Comment 會嘗試保持任何現有註解的樣式,以維護任何縮排、維持行的語法之前,可以維持註解是要與程式碼項目接觸或是要以空白行分隔等,

.NET Framework 安全性

請參閱

參考

VCCodeDelegate 介面

Microsoft.VisualStudio.VCCodeModel 命名空間

其他資源

如何:編譯和執行 Automation 物件模型程式碼範例