Export (0) Print
Expand All
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

dataformatas attribute | dataFormatAs property

Sets or retrieves the rendering format for the data supplied to the object.

Syntax

HTML<element dataformatas="p" ... >
JavaScript

p = object.dataFormatAs

 

Property values

Type: String

text

Default. Data is rendered as text.

html

Data is rendered as HTML.

localized-text

A Windows Store app using JavaScript versions. Data is rendered using the locale settings of the client machine.

Remarks

The dataFld property is not available on param objects; use getAttribute('dataFld') instead.

Examples

The following div example renders data in HTML format.


<div datafld="Column2" dataformatas="html"></div>

The following span example renders data in HTML format.


<span datasrc="#bank_acct" datafld="balance" dataformatas="html"></span>

The following textArea example renders data in text format.


<textarea datasrc="#customer" datafld="address" dataformatas="text" rows=6 COLS=60></textarea>

See also

button
div
input type=button
label
legend
object
option
select
span
table
Introduction to Data Binding

 

 

Show:
© 2015 Microsoft