HtmlTextWriter.TagLeftChar 欄位
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
表示標記的開頭角括弧 (<)。
public: char TagLeftChar;
C#
public const char TagLeftChar;
val mutable TagLeftChar : char
Public Const TagLeftChar As Char
下列程式碼範例會以專案名稱呈現專案開頭標記的第一 <table>
個字元。 程式碼範例會 Write 使用 方法搭配 TagLeftChar 欄位做為參數。
此程式碼範例會轉譯下列標記:
<table
C#
// Create the opening tag of a table element
// with styles by using the HtmlTextWriter class.
writer.Write(HtmlTextWriter.TagLeftChar);
writer.Write("table");
' Create the opening tag of a table element
' with styles by using the HtmlTextWriter class.
writer.Write(HtmlTextWriter.TagLeftChar)
writer.Write("table")
撰寫 TagLeftChar 標記標記時,、 WriteFullBeginTag 和 WriteEndTag 方法會使用 RenderBeginTagWriteBeginTag 欄位。
產品 | 版本 |
---|---|
.NET Framework | 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |