HtmlTextWriter.TagRightChar HtmlTextWriter.TagRightChar HtmlTextWriter.TagRightChar HtmlTextWriter.TagRightChar Field

定義

表示標記的結尾角括弧 (>)。Represents the closing angle bracket (>) of a markup tag.

public: char TagRightChar;
public const char TagRightChar;
val mutable TagRightChar : char
Public Const TagRightChar As Char 

欄位值

範例

下列程式碼範例示範如何藉由呼叫<table> Write方法的多載來呈現專案的結束記號。The following code example shows how to render the closing tag of a <table> element by making calls to overloads of the Write method. 為了呈現標記的最後一個字元,程式碼範例會使用Write方法TagRightChar搭配欄位做為參數。To render the final character of the tag, the code example uses the Write method with the TagRightChar field as a parameter.

這個程式碼範例會呈現下列標記:This code example renders the following markup:

</table>

// Write the closing tag of a table element.
writer.Write(HtmlTextWriter.EndTagLeftChars);
writer.Write("table");
writer.Write(HtmlTextWriter.TagRightChar);
writer.WriteLine();
' Write the closing tag of a table element.
writer.Write(HtmlTextWriter.EndTagLeftChars)
writer.Write("table")
writer.Write(HtmlTextWriter.TagRightChar)
writer.WriteLine()

備註

寫入標記標記時RenderBeginTagWriteFullBeginTag、和WriteEndTag方法會使用欄位。TagRightCharThe TagRightChar field is used by the RenderBeginTag, WriteFullBeginTag, and WriteEndTag methods when writing markup tags.

適用於

另請參閱