DHTMLX Docs & Samples Explorer

Index
dhtmlxdataview
API Methods

## Object constructor

There are two possible syntaxes of DataView constructor

#### Simple

        var view = new dhtmlXDataView("container_id")

Where container_id - id of html container, inside which dataview will be initialized.

#### Detailed

        var view = new dhtmlXDataView({
            container:"container_id",
            drag:true,
            select:true,
            template:some
        });

Where

- container - {mixed} ID of html container inside which item will be rendered
  - ID of HTML element
  - HTML object
- drag - {bool} enables dnd
  - true - dnd allowed
  - false - dnd denied
- select - {mixed} defines selection mode
  - false - selection is denied
  - true - single selection is allowed
  - “multiselect” - multiselection is allowed
- type - {mixed} name of render-type, or custom template
  - name of type
  - type object, check Templates
- height - {string} can be set as “auto” to force auto-height
  - “auto” - force auto-height mode
- pager - pading control settings
  - pager object, check Paging
- tooltip - tooltip object settings
  - tooltip object

        var view = new dhtmlXDataView({
            container:"container_id",
            tootlip:{
            	template:"Details: #property#"
            }
        });