SPMobileItemFieldIterator.DefaultTemplateName Property

Gets the name of the default template for the current list.

Namespace:  Microsoft.SharePoint.MobileControls
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)


Public Overrides ReadOnly Property DefaultTemplateName As String

Dim instance As SPMobileItemFieldIterator
Dim value As String

value = instance.DefaultTemplateName
public override string DefaultTemplateName { get; }

Property Value

Type: System.String
A String that represents the name of the list's default template.


In Windows SharePoint Services 3.0 this property always returns "MobileListFieldIterator". Notice the slight mismatch between the property value and the name of the control: "List" instead of "Item".

The DefaultTemplateName property holds the value of the ID attribute of a <RenderingTemplate> element in the file MobileDefaultTemplates.ascx located in C:\\Program Files\Common Files\Microsoft Shared\web server extensions\12\TEMPLATE\CONTROLTEMPLATES. .

You must not modify MobileDefaultTemplates.ascx. To customize the rendering of this control, create another <RenderingTemplate>element in a new .ascx file in the ...\CONTROLTEMPLATES folder. Give your new <RenderingTemplate> element an ID value that is descriptive but likely to be unique. For example, you could add your company name to the end of the ID, such as "MobileListFieldIteratorMyCompanyInc". Then derive a new class from SPMobileComponent (the same parent as SPMobileItemFieldIterator), and override its DefaultTemplateName property so that it returns your custom ID.

See Also


SPMobileItemFieldIterator Class

SPMobileItemFieldIterator Members

Microsoft.SharePoint.MobileControls Namespace