Syntax

expression.DefaultValue

expression A variable that represents a ListDataFormat object.

Remarks

This property is used only for tables linked to a Microsoft Windows SharePoint Services site.

In Excel, you cannot set any of the properties associated with the object. You can set these properties, however, by modifying the list on the SharePoint site.

Example

The following example displays the setting of the DefaultValue property for the third column of the table in Sheet1 of the active workbook. This code requires a list linked to a SharePoint site.

Visual Basic for Applications
Sub ShowDefaultSetting() Dim wrksht As Worksheet Dim objListCol As ListColumn Set wrksht = ActiveWorkbook.Worksheets("Sheet1") Set objListCol = wrksht.ListObjects(1).ListColumns(3) If IsNull(objListCol.ListDataFormat.DefaultValue) Then MsgBox "No default value specified." Else MsgBox objListCol.ListDataFormat.DefaultValue End If End Sub
default default value DefaultValue defaultvalue property

See also: