Redigeeri

Jagamisviis:


HtmlTextWriter.WriteStyleAttribute Method

Definition

Writes a style attribute and its value to the output stream.

Overloads

WriteStyleAttribute(String, String, Boolean)

Writes the specified style attribute and value to the output stream, and encodes the value, if specified.

WriteStyleAttribute(String, String)

Writes the specified style attribute to the output stream.

WriteStyleAttribute(String, String, Boolean)

Writes the specified style attribute and value to the output stream, and encodes the value, if specified.

public:
 virtual void WriteStyleAttribute(System::String ^ name, System::String ^ value, bool fEncode);
public virtual void WriteStyleAttribute (string name, string value, bool fEncode);
abstract member WriteStyleAttribute : string * string * bool -> unit
override this.WriteStyleAttribute : string * string * bool -> unit
Public Overridable Sub WriteStyleAttribute (name As String, value As String, fEncode As Boolean)

Parameters

name
String

The style attribute to write to the output stream.

value
String

The value assigned to the style attribute.

fEncode
Boolean

true to encode the style attribute and its assigned value; otherwise, false.

Remarks

The WriteStyleAttribute method writes the style attribute in the following form:

name = value ;

The HtmlAttributeEncode method is used to encode the value parameter.

See also

Applies to

WriteStyleAttribute(String, String)

Writes the specified style attribute to the output stream.

public:
 virtual void WriteStyleAttribute(System::String ^ name, System::String ^ value);
public virtual void WriteStyleAttribute (string name, string value);
abstract member WriteStyleAttribute : string * string -> unit
override this.WriteStyleAttribute : string * string -> unit
Public Overridable Sub WriteStyleAttribute (name As String, value As String)

Parameters

name
String

The style attribute to write to the output stream.

value
String

The value assigned to the style attribute.

Remarks

The WriteStyleAttribute method writes the style attribute in the following form:

name = value ;

See also

Applies to