ControlBuilder.AppendLiteralString(String) ControlBuilder.AppendLiteralString(String) ControlBuilder.AppendLiteralString(String) ControlBuilder.AppendLiteralString(String) Method

Definition

Adds the specified literal content to a control. This method is called by the ASP.NET page framework.

public:
 virtual void AppendLiteralString(System::String ^ s);
public virtual void AppendLiteralString (string s);
abstract member AppendLiteralString : string -> unit
override this.AppendLiteralString : string -> unit
Public Overridable Sub AppendLiteralString (s As String)

Parameters

s
String String String String

The content to add to the control.

Exceptions

The string literal is not well formed.

Examples

// Override the AppendLiteralString method so that literal
// text between rows of controls are ignored.  
public override void AppendLiteralString(string s) 
{
  // Ignores literals between rows.
}
  ' Override the AppendLiteralString method so that literal
  ' text between rows of controls are ignored.  
  Public Overrides Sub AppendLiteralString(s As String)
  End Sub 'AppendLiteralString
End Class 'MyItemControlBuilder ' Ignores literals between rows.

Remarks

Override the AppendLiteralString method to control how literal content between the control's opening and closing tags is processed. Literal content can be any text that is passed by the browser to the server control. For example, any HTML elements and text, between their opening and closing tags, are literal content.

Applies to