This documentation is archived and is not being maintained.

ControlBuilder.AppendLiteralString Method

Adds literal content to a control.

[Visual Basic]
Public Overridable Sub AppendLiteralString( _
   ByVal s As String _
)
[C#]
public virtual void AppendLiteralString(
 string s
);
[C++]
public: virtual void AppendLiteralString(
 String* s
);
[JScript]
public function AppendLiteralString(
   s : String
);

Parameters

s
The content to add to the control.

Remarks

Literal content is 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.

Example

[Visual Basic] 
' 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.

[C#] 
// Override the AppendLiteralString method so that literal
// text between rows of controls are ignored.  
public override void AppendLiteralString(string s) 
{
  // Ignores literals between rows.
}

[C++] 
// Override the AppendLiteralString method so that literal
// text between rows of controls are ignored.
public:
   void AppendLiteralString(String* s) {
// Ignores literals between rows.
   }

[JScript] No example is available for JScript. To view a Visual Basic, C#, or C++ example, click the Language Filter button Language Filter in the upper-left corner of the page.

Requirements

Platforms: Windows 2000, Windows XP Professional, Windows Server 2003 family

See Also

ControlBuilder Class | ControlBuilder Members | System.Web.UI Namespace

Show: