[]
The following table lists the gc-column elements:
Attribute | SpreadJS API | Type | Comment |
---|---|---|---|
dataField |
|
| Set for Worksheet.bindColumn(index, columnInfo) function |
headerText |
|
| Set for Worksheet.bindColumn(index, columnInfo) function |
width |
|
| |
visible |
|
| |
resizable |
|
| |
autoFit |
|
| If autoFit is true, the column applies automatic fit after data binding |
style |
|
| Set the column style |
headerStyle |
|
| Set the column header style |
cellType |
|
| |
formatter |
|
|
The following code sample uses the column element.
@Component({
selector: 'my-app',
template: `<gc-spread-sheets>
<gc-worksheet>
<gc-column [width]="columnWidth" [style]="columnStyle"></gc-column>
</gc-worksheet>
</gc-spread-sheets>`,
})
export class AppComponent {
columnWidth: 300;
columnStyle = new GC.Spread.Sheets.Style();
}