Tuesday, November 1, 2011

Creating a Wiki Page template For SharePoint 2010 Foundation

style="PADDING-BOTTOM: 10px; MARGIN: 1px 0px; PADDING-LEFT: 13px; PADDING-RIGHT: 0px; COLOR: #e9ab17; FONT-WEIGHT: bold; PADDING-TOP: 10px">Introduction


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">As
I have ever written several time in my previous posts, one of the severe
limitation of SharePoint Foundation is that the Wiki Pages are based on a single
template wkpstd.aspx located at


C:\Program Files\Common Files\Microsoft Shared\Web Server
Extensions\14\TEMPLATE\DocumentTemplates


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">If
you try to add a wiki page programmatically to a wiki page library of
a SharePoint Foundation team site and you want it to be ghosted you must
use the method SPFileCollection.Add with this signature :


 href="http://msdn.microsoft.com/en-us/library/aa543347.aspx">color=#0033cc>Add(String, SPTemplateFileType)


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">And
pass the reference of the wiki page template wkpstd.aspx to the SPTemplate
parameter. If you use any other signature, you will be able to add a wikipage, but
it will be unghosted.


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">I
am now going to show you a very amazing workaround to use another template than
the wkpstd.aspx one and will process in  two steps. First I will
demonstrate it so as you can easily understand its principle then I will provide
a programmatic way of doing it.


style="PADDING-BOTTOM: 10px; MARGIN: 1px 0px; PADDING-LEFT: 13px; PADDING-RIGHT: 0px; COLOR: #e9ab17; FONT-WEIGHT: bold; PADDING-TOP: 10px">Demonstration


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">Start
creating your new template by duplicating the wkpstd.aspx and rename it
wkpcustom.aspx, then perform a little operation of customization in order each
page based on this new template can tell its name :


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">In
the page directive section add the namespace System.Diagnostics because the wiki
pages will tell their nam in the debugView...


<%size=2>@ color=#a31515 size=2>Import color=#ff0000 size=2>Namespacecolor=#0000ff size=2>size=2>="System.Diagnostics" %>


Then, at the top of the PlaceHolderMain section paste this code:

size=2>

size=2>protected size=2>override
size=2>void OnPreInit(size=2>EventArgs
e)
{
size=2>     basesize=2>.OnPreInit(e);

color=#2b91af size=2>    Debugsize=2>.WriteLine(size=2>SPContextsize=2>.Current.File.Name);
}


 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">Then,
we are going to prepare a feature to reference this wkpcustom.aspx file in a
SharePoint Foundation wiki page library.


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">Assume
we call the feature


 Provisioning.SPF_WikiPages


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">Here
is the feature.xml code:


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US><?
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>xml
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>
style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>version
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>=
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>"1.0"
encodingstyle="COLOR: blue">="utf-8"style="COLOR: blue">?>"urn:schemas-microsoft-com:office:office" />


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US><
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Feature
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>
style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Id
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>=
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>"style="COLOR: blue">00BFEA71-2062-426C-90BF-714C59600AAA"


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Title
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>=
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>"Adding pre populate wiki
pages
"


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Description
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>=
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>"This feature will add pre-populate wiki
pages to the site pages wiki library of this site
"


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Version
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>=
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>"1.0.0.0"


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Scope
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>=
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>"Web"


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Hidden
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>=
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>"false"


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>DefaultResourceFile
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>=
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>"core"


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>xmlns
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>=
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>"style="COLOR: blue">http://schemas.microsoft.com/sharepoint/"style="COLOR: blue">>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes"><style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-no-proof: yes">ElementManifestsstyle="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes">>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes">style="mso-spacerun: yes">    <style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-no-proof: yes">ElementManifeststyle="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes">
style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-no-proof: yes">Locationstyle="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes">=style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-no-proof: yes">"style="COLOR: blue">elements.xml"
/>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes">style="mso-spacerun: yes">  </style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-no-proof: yes">ElementManifestsstyle="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes">>


style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes"></style="LINE-HEIGHT: 115%; FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-no-proof: yes">Featurestyle="LINE-HEIGHT: 115%; FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes">>


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">And
this is the xml code of the elements.xml file


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US><
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Elements
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>
style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>xmlns
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>=
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>"style="COLOR: blue">http://schemas.microsoft.com/sharepoint/color=#000000>"style="COLOR: blue">>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>  <
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Module
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>
style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Url
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>=
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>"style="COLOR: blue">SitePages"style="COLOR: blue"> >


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>   
<
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>File
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>
style="FONT-FAMILY: 'Courier New'; COLOR: red; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Url
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>=
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>"style="COLOR: blue">wkpcustom.aspx"style="COLOR: blue"> Typestyle="COLOR: blue">="style="COLOR: blue">GhostableInLibrary"style="COLOR: blue">></style="COLOR: #a31515">Filestyle="COLOR: blue">>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes"></style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-no-proof: yes">Modulestyle="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes">>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes"></style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-no-proof: yes">Elementsstyle="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes">>


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">color=#000000 size=3 face="Times New Roman"> 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">Last,
a screen shot of the Provisioning.SPF_WikiPages feature folder








 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">Then,
install the feature and activate it for one of the team site of your Farm and
you will have a reference to your page in the site pages library of this team
site.









 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">You
can see a reference to the wkpcustom file located in the feature folder on the
server









 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">And
because this file was provisioned by a feature, although there is in line code
in it, if you display the wiki page using this file, it will work, the code
will run and will write the name of the page in the debugview.








 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">But,
wait a minute, this file is already a template. It is a template for just one
page within the site pages library but it is exactly like the wkpstd.aspx for
the other pages. So assume we could have several pages within the library based
on this file we would have created a new template. I see some of you
smiling...


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">You
have understood... It is what we are going to do now...


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">Now
is the time to use another workaround I have already shown in a previous post to
open our library in explorer mode.
So switch to shared documents library,
open it in explorer mode, then using the explorer folder navigation go back to
the site pages library but in explorer mode now








 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">Then
rename the page in "page 01.aspx"








 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">then
go back to the site pages library within the SharePoint UI. You will notice that
the page is renamed and if you displayed it, its name in the debugview has
changed too. While renamed, the page remains in its ghosted state and linked
to the "template".








 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">Now
deactivate the feature, then reactivate it and you will have a new page
wkpcustom.aspx beside the "page 01.aspx" and the two pages are linked to the
same file on the server, so if we display one then the other, debugview will
trace the two names based on the code of an unique file on the server: we have
created our first custom template for a wiki page library in SharePoint
Foundation!








 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">Now
we have done the demonstration we just have to find the way to do it
programmatically:


style="PADDING-BOTTOM: 10px; MARGIN: 1px 0px; PADDING-LEFT: 13px; PADDING-RIGHT: 0px; COLOR: #e9ab17; FONT-WEIGHT: bold; PADDING-TOP: 10px">Coding
the sequence


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">this
applicative page called from your site will provision 9 pages in your site
page library pointing on the same unique template wkpcustom.aspx located in the
feature folder. If you modify the file in the folder, you will modify the 9
pages


 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; BACKGROUND: yellow; FONT-SIZE: 10pt; mso-no-proof: yes; mso-highlight: yellow"><%style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes">@style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-no-proof: yes"> style="COLOR: #a31515">Page Languagestyle="COLOR: blue">="C#" style="COLOR: red">AutoEventWireupstyle="COLOR: blue">="true" Inheritsstyle="COLOR: blue">="Microsoft.SharePoint.WebControls.LayoutsPageBase"


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-no-proof: yes">style="mso-spacerun: yes">    style="COLOR: red">DynamicMasterPageFilestyle="COLOR: blue">="~masterurl/default.master" style="BACKGROUND: yellow; mso-highlight: yellow">%>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; BACKGROUND: yellow; FONT-SIZE: 10pt; mso-no-proof: yes; mso-highlight: yellow"> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; BACKGROUND: yellow; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes; mso-highlight: yellow"
lang=EN-US><%
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>@
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> Assembly style="COLOR: red">Name="System.Core,
Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"
style="BACKGROUND: yellow; mso-highlight: yellow">%>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; BACKGROUND: yellow; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes; mso-highlight: yellow"
lang=EN-US><%
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>@
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> Import style="COLOR: red">Namespacestyle="COLOR: blue">="Microsoft.SharePoint" style="BACKGROUND: yellow; mso-highlight: yellow">%>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; BACKGROUND: yellow; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes; mso-highlight: yellow"
lang=EN-US><%
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>@
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> Import style="COLOR: red">Namespacestyle="COLOR: blue">="Microsoft.SharePoint.Administration" style="BACKGROUND: yellow; mso-highlight: yellow">%>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; BACKGROUND: yellow; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes; mso-highlight: yellow"
lang=EN-US><%
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>@
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> Import style="COLOR: red">Namespacestyle="COLOR: blue">="System.Text" style="BACKGROUND: yellow; mso-highlight: yellow">%>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; BACKGROUND: yellow; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes; mso-highlight: yellow"
lang=EN-US><%
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>@
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> Import style="COLOR: red">Namespacestyle="COLOR: blue">="System.Linq" style="BACKGROUND: yellow; mso-highlight: yellow">%>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; BACKGROUND: yellow; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes; mso-highlight: yellow"
lang=EN-US><%
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>@
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> Assembly style="COLOR: red">Name="Microsoft.SharePoint,
Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c"
style="BACKGROUND: yellow; mso-highlight: yellow">%>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="BACKGROUND: yellow; mso-highlight: yellow">
 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US><
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>asp
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>:
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>content
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> idstyle="COLOR: blue">="PageHead" style="COLOR: red">contentplaceholderidstyle="COLOR: blue">="PlaceHolderAdditionalPageHead" style="COLOR: red">runatstyle="COLOR: blue">="server">


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US></
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>asp
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>:
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>content
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US><
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>asp
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>:
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>content
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> idstyle="COLOR: blue">="Main" style="COLOR: red">contentplaceholderidstyle="COLOR: blue">="PlaceHolderMain" style="COLOR: red">runatstyle="COLOR: blue">="server">


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US><
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>script
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> languagestyle="COLOR: blue">="C#" runatstyle="COLOR: blue">="server">


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>    style="COLOR: blue">protected override
void OnLoad(style="COLOR: #2b91af">EventArgs e)


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>   
{


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">       
base.OnLoad(e);


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">       
SPWeb myWeb = SPContext.Current.Web;


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">       
myWeb.AllowUnsafeUpdates = style="COLOR: blue">true;


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">       
for (style="COLOR: blue">int i = 1; i < 10; i++)


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">       
{


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
if (myWeb.Features[style="COLOR: blue">new Guid(style="COLOR: #a31515">"{00BFEA71-2062-426C-90BF-714C59600AAA}")] !=
null)


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
{


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">              
 myWeb.Features.Remove(style="COLOR: blue">new Guid(style="COLOR: #a31515">"{00BFEA71-2062-426C-90BF-714C59600AAA}"));


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
}


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
myWeb.Features.Add(new style="COLOR: #2b91af">Guid(style="COLOR: #a31515">"{00BFEA71-2062-426C-90BF-714C59600AAA}"));


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
SPList myList = myWeb.Lists["Site
Pages"
];


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
SPListItem myItem = style="COLOR: blue">null;


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
SPContext.Current.Web.AllowUnsafeUpdates = style="COLOR: blue">true;


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
foreach (SPListItem anItem style="COLOR: blue">in myList.Items)


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
{


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">               
if (anItem.Name == style="COLOR: #a31515">"wkpcustom.aspx")


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">               
{


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">                   
myItem = anItem;


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">               
}


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
}


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
string destinationUrl = myWeb.Url +
"/" + myList.RootFolder.Url + style="COLOR: #a31515">"/" + style="COLOR: #a31515">"Wiki_page0" + i + style="COLOR: #a31515">".aspx";


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
myItem.File.MoveTo(destinationUrl);


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
myItem.File.Update();


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">           
myWeb.Features.Remove(new style="COLOR: #2b91af">Guid(style="COLOR: #a31515">"{00BFEA71-2062-426C-90BF-714C59600AAA}"));


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">       
}


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>style="mso-spacerun: yes">       
lbl1.Text = "Your files has been
provisionned successfully..."
;


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>   
}


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US></
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>script
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US><
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>asp
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>:
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Label
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> runatstyle="COLOR: blue">="server" IDstyle="COLOR: blue">="lbl1" style="COLOR: blue">></aspstyle="COLOR: blue">:Labelstyle="COLOR: blue">>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US></
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>asp
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>:
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>content
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US><
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>asp
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>:
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>content
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> idstyle="COLOR: blue">="PageTitle" style="COLOR: red">contentplaceholderidstyle="COLOR: blue">="PlaceHolderPageTitle" style="COLOR: red">runatstyle="COLOR: blue">="server">


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Provisioning Team Site Wiki Pages


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US></
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>asp
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>:
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>content
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>>


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US><
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>asp
style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>:
style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>content
style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> idstyle="COLOR: blue">="PageTitleInTitleArea" style="COLOR: red">contentplaceholderidstyle="COLOR: blue">="PlaceHolderPageTitleInTitleArea"


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>    style="COLOR: red">runatstyle="COLOR: blue">="server">


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US>Provisioning Team Site Wiki Pages


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; FONT-SIZE: 10pt; mso-ansi-language: EN-US; mso-no-proof: yes"
lang=EN-US> 


class=MsoNormal>style="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes"></style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-no-proof: yes">aspstyle="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes">:style="FONT-FAMILY: 'Courier New'; COLOR: #a31515; FONT-SIZE: 10pt; mso-no-proof: yes">contentstyle="FONT-FAMILY: 'Courier New'; COLOR: blue; FONT-SIZE: 10pt; mso-no-proof: yes">>


face=Calibri> 



 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">Here
are the screen shots of the applicative page after its provisioning job is
finished








 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">and
the site pages library with the 9 new pages








 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">And
if I call the 9 pages, each of them will tell me its name.








 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">And
now, I have changed the instruction of the name displaying in the template, and I
have called back the 9 pages and here is the result.








 


style="TEXT-ALIGN: justify; PADDING-BOTTOM: 18px; MARGIN: 1px 0px; PADDING-LEFT: 18px; PADDING-RIGHT: 5px; FONT-FAMILY: arial; COLOR: gray; FONT-SIZE: 10pt; FONT-WEIGHT: normal; PADDING-TOP: 5px">Have
a lot of fun with that!