Layout API

Provides run-time access to the Layout function and Layout State

Layout API Methods

MethodDescription
cloneAndSetLayout(layoutToClone, layoutName)Creates new Layout based on given Layout but with name provided and then loads it into Grid
cloneLayout(layoutToClone, layoutName)Creates new Layout based on given Layout but with name provided
createAndSetLayout(layoutToCreate)Creates new Layout in the state and then loads it into Grid
createLayout(layoutToCreate)Creates new Layout in the state
doesLayoutExist(layout)Checks whether this Layout exists in the Adaptable State (by comparing Uuid property)
fireLayoutUpdatedEvent(layout, layoutUpdatedTrigger)Fires the Layout Updated Event (when a layout is added, updated or deleted)
getAllLayout()Retrieves all Layouts in Adaptable State
getCurrentLayout()Retrieves Current Layout from Layout State
getCurrentLayoutName()Retrieves name of current Layout
getCurrentVisibleColumnIds()Retrieves array of visible ColumnIds in current Layout
getCurrentVisibleColumnIdsMap()Retrieves map with visible columns in current Layout
getLayoutByName(layoutName)Retrieves Layout with the given name
getLayoutState()Retrieves Layout section from Adaptable State
saveCurrentLayout()Saves current Layout - using column order, visibility, sorting etc. currently in use in the grid
saveLayout(layoutToSave)Saves given Layout into Adaptable State
setLayout(layoutName)Sets (i.e. selects) the Layout
shouldAutoSaveLayout(layout)Whether this Layout should be auto saved (based on Layout State and Layout Options)
showLayoutPopup()Opens Layout popup screen

See API documentation for full details of all available functions with lists of parameters

More Information