ListObject::DataBoundFormat Property

 

Gets or sets the format style for data-bound ListObject controls.

Namespace:   Microsoft.Office.Tools.Excel
Assembly:  Microsoft.Office.Tools.Excel (in Microsoft.Office.Tools.Excel.dll)

property XlRangeAutoFormat DataBoundFormat {
	XlRangeAutoFormat get();
	void set(XlRangeAutoFormat value);
}

The ListObject control must be bound to data before you can use this property.

The specified format is applied to the entire list object, including rows that are added later.

To remove formatting, set DataBoundFormat to xlRangeAutoFormatNone.

Use DataBoundFormatSettings to exclude specific types of formatting such as pattern, font, or width from the style.

The following code example creates a DataTable and a ListObject, and binds the ListObject to the DataTable. It then uses an XlRangeAutoFormat value to format the ListObject.

This example is for a document-level customization.

No code example is currently available or this language may not be supported.
Return to top
Show: