SheetAPI.createSheetApp method is used to create sheet application. This is the first API need to be called in your file.
{
withoutTitlebar: true,
withoutSheetbar: true,
withoutToolbar: true,
withoutContentbar: true,
withoutSidebar: true
}
See the following image for the bar definition in the sheet panel.
The handle information of the Sheet application just created
{
appCt: the container of the sheet application, which contains the sheet and some toolbar
sheet: the sheet itself
store: the store of sheet application
}
For detail, please see document Render Sheet UI in HTML DIV.
Ext.onReady(function(){
SCONFIG.setupDir('');
SHEET_API = Ext.create('EnterpriseSheet.api.SheetAPI', {
openFileByOnlyLoadDataFlag: true
});
SHEET_API_HD = SHEET_API.createSheetApp({
withoutTitlebar: true,
withoutSheetbar: true,
withoutToolbar: true,
withoutContentbar: true,
withoutSidebar: true,
renderTo: 'sheet-markup',
style: 'background:white;border-left:1px solid silver;',
height: '100%'
});
SHEET_API.loadData(SHEET_API_HD, {
fileName: 'Example Sheet',
sheets: [{
name: 'First tab',
id: 1
}],
cells: [{
sheet: 1,
row: 1,
col: 1,
json: {data: 110}
}]
});
document.documentElement.style.background = 'none';
Ext.getBody().setStyle('background-image', 'none');
});