Share via


Propriedade SPMobilePageContents.DefaultTemplateName

Gets the value of the ID attribute of the <RenderingTemplate> element that defines the rendering of the contents when the control is on the home page on a mobile Web site.

Espaço para nome Microsoft.SharePoint.MobileControls
Conjunto de Módulos (Assembly) Microsoft.SharePoint (em microsoft.sharepoint.dll)

A sintaxe

  Public Overrides ReadOnly Property DefaultTemplateName As String
Dim instance As SPMobilePageContents
Dim value As String

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

A propriedade Value

Um String que representa a identificação do modelo para o home page.

Comentários

Windows SharePoint Services 3.0 essa propriedade sempre retorna "MobileHomePageContents".This is 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.

Você não deve modificar MobileDefaultTemplates.ascx.To customize the rendering of the home page contents, 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.De exemplo, você pode adicionar seu nome da empresa ao final de identificação, such as "MobileHomePageContentsMyCompanyInc".Em seguida, derive uma nova classe de SPMobileComponent, (o mesmo pai como SPMobilePageContents) e substituir seus DefaultTemplateName DefaultTemplateName propriedade para que ela retorna sua personalizado ID.Add an object of the new class to the <SPMobileForm> element of a mobile Web page.

Contrast the DefaultTemplateName property with the TemplateName property which specifies the <RenderingTemplate> when the page is Não o home page do site móvel.

Consulte também

Referência

SPMobilePageContents De classe
SPMobilePageContents Membros
Microsoft.SharePoint.MobileControls De espaço para nome