<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom"><title type="text">Blog posts by Per Hemmingson</title><link href="http://world.optimizely.com" /><updated>2010-01-28T17:39:07.0000000Z</updated><id>https://world.optimizely.com/blogs/Per-Hemmingson/</id> <generator uri="http://world.optimizely.com" version="2.0">Optimizely World</generator> <entry><title>EPiServer World News</title><link href="https://world.optimizely.com/blogs/Per-Hemmingson/Dates/2010/1/EPiServer-World-News/" /><id>&lt;p&gt;A week ago we upgraded EPiServer World to the release candidate for EPiServer CMS 6 with the motto “Drinking our own champagne” and put it to the real test.&lt;/p&gt;  &lt;p&gt;I have previously written about &lt;a href=&quot;http://world.episerver.com/Blogs/Per-Hemmingson/Dates/2008/10/EPiServer-CMS-R2-Upgrade-experience/&quot;&gt;upgrade&lt;/a&gt; experiences for EPiServer CMS 5 R2 and its breaking changes. The great thing about CMS 6 is that there are no breaking changes, and the upgrade process is actually a lot easier than before* (for our website). The Development team has done a superb job of creating a stable release as well as a smooth upgrade script. The actual upgrade took 5 minutes with EPiServer Deployment Center, then you just sit and wait while it migrates all XForms data to the new &lt;a href=&quot;http://world.episerver.com/Blogs/Paul-Smith/Dates1/2009/12/Dynamic-Data-Store-Feature-List-in-EPiServer-CMS-6-Release-Candidate/&quot;&gt;Dynamic data store.&lt;/a&gt;&amp;#160;&lt;/p&gt;  &lt;p&gt;There are of course other changes that &lt;a href=&quot;http://world.episerver.com/Blogs/Per-Bjurstrom/Archive/2009/12/Upgrading-to-CMS-6-RC1/&quot;&gt;Per Bjurstr&#246;m&lt;/a&gt; has already blogged about that you should read up on. &lt;/p&gt;  &lt;p&gt;The site worked without recompiling the code, but there is some obsolete code functionality in XForms (pageAfterPost) and the FriendlyUrlRewriteProvider, to name a few that you should update.&lt;/p&gt;  &lt;p&gt;We also have updated EPiServer World with new functionality and corrected some bugs, especially with WebEx/online sessions. &lt;/p&gt;  &lt;p&gt;Most notably we have added a new forum feature, Mark as Answered:&lt;/p&gt;  &lt;p&gt;&lt;a href=&quot;/link/e3fac32eb6824affba9188cc629e4b26.png&quot;&gt;&lt;img style=&quot;border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px&quot; title=&quot;image&quot; border=&quot;0&quot; alt=&quot;image&quot; src=&quot;/link/01ac9eaf248d4755a4f7b5259aafa59a.png&quot; width=&quot;320&quot; height=&quot;70&quot; /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;When you select to Mark as answer, the answered post will look like this:&lt;/p&gt;  &lt;p&gt;&lt;a href=&quot;/link/96b8f50904b641ab8c7087a499c55166.png&quot;&gt;&lt;img style=&quot;border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px&quot; title=&quot;image&quot; border=&quot;0&quot; alt=&quot;image&quot; src=&quot;/link/92f3429b248c439da22563491b95752b.png&quot; width=&quot;404&quot; height=&quot;130&quot; /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;This has been implemented so that it is quicker to find answers to your problems as well as to answer unanswered questions. We are also working on a Community recognition program so you will get points for contributing to our EPiServer Community, and forum posts marked as answered will of course receive more points.&lt;/p&gt;  &lt;p&gt;The second new feature added is a feedback form so you can send us comments, suggestions and errors you find on the site:&lt;/p&gt;  &lt;p&gt;&lt;a href=&quot;/link/250cf9160144433b911dbb1c6dff9847.png&quot;&gt;&lt;img style=&quot;border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px&quot; title=&quot;image&quot; border=&quot;0&quot; alt=&quot;image&quot; src=&quot;/link/d875cd1cb4a549ef972d3947589b1e04.png&quot; width=&quot;404&quot; height=&quot;282&quot; /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;You can still use the mailbox &lt;a href=&quot;mailto:epw@episerver.com&quot;&gt;epw@episerver.com&lt;/a&gt;&amp;#160; Note that we use Email Obfuscator to protect all e-mail addresses on our sites.&lt;/p&gt;  &lt;p&gt;A lot more new requested functionality is in the pipeline and we are continually updating the site to ensure that there is one World to rule them all. :-)&lt;/p&gt;</id><updated>2010-01-28T17:39:07.0000000Z</updated><summary type="html">Blog post</summary></entry> <entry><title>Getting EPiServer FileManager into Relate+ clubs</title><link href="https://world.optimizely.com/blogs/Per-Hemmingson/Dates/2009/10/Getting-EPiServer-FileManager-into-Relate-clubs/" /><id>&lt;p&gt;Having the possibility to upload files into EPiServer Community Clubs has internally been a highly requested feature on our Intranet site. Since the EPiServer.FileManger that you see in our Demo templates are based on EPiServer CMS pages and files stored into the current page folder that will not work for Community clubs that are not based on pages.&lt;br /&gt;&lt;/p&gt; &lt;p&gt;Well after some discussion with my colleagues the solution was quite simple; Combine how EPiServer Blog uploads file with the &lt;a href=&quot;http://world.episerver.com/en/Articles/Items/Working-With-Demo-Templates-for-EPiServer-CMS-5-R2-SP1/&quot; target=&quot;_blank&quot;&gt;Workroom File Manager&lt;/a&gt; web control.&lt;/p&gt; &lt;p&gt;First of create an ClubFile page type and add it to your Relate+ project. Then from &lt;a href=&quot;http://world.episerver.com/Download/Items/EPiServer-CMS/Version-5/EPiServer-CMS-5-R2-SP1/EPiServer-CMS-5-R2-SP1-Demo-Templates/&quot; target=&quot;_blank&quot;&gt;EPiServer Demo Templates&lt;/a&gt; add/take:&lt;/p&gt; &lt;ul&gt; &lt;li&gt;EPiServer.FileManger Web control  &lt;/li&gt;&lt;li&gt;The usercontrols in EPiServer.Templates.Demo.FileManager  &lt;/li&gt;&lt;li&gt;FileManager and extensions images under Templates/Demo/Styles/Default/images  &lt;/li&gt;&lt;li&gt;Stylesheet specific for Filemanager in styles.css (File manager control, Toolbar buttons, Documents)  &lt;/li&gt;&lt;li&gt;File Manager language texts from demo_en.xml in lang folder.  &lt;/li&gt;&lt;li&gt;Lastly, the EPiCheckBox class which is in /Templates/Demo/Workroom/Core/EPiCheckBox.cs&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;In Web config you register the File Manager Web control,&lt;/p&gt; &lt;div class=&quot;csharpcode-wrapper&quot; id=&quot;codeSnippetWrapper&quot;&gt; &lt;div class=&quot;csharpcode&quot; id=&quot;codeSnippet&quot;&gt; &lt;div class=&quot;csharpcode-wrapper&quot; id=&quot;codeSnippetWrapper&quot;&gt; &lt;div class=&quot;csharpcode&quot; id=&quot;codeSnippet&quot;&gt; &lt;div class=&quot;csharpcode-wrapper&quot; id=&quot;codeSnippetWrapper&quot;&gt; &lt;div id=&quot;codeSnippetWrapper&quot; style=&quot;border-right: silver 1px solid; padding-right: 4px; border-top: silver 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: silver 1px solid; width: 83.12%; cursor: text; direction: ltr; max-height: 200px; line-height: 12pt; padding-top: 4px; border-bottom: silver 1px solid; font-family: &#39;Courier New&#39;, courier, monospace; height: 122px; background-color: #f4f4f4; text-align: left&quot;&gt; &lt;div id=&quot;codeSnippet&quot; style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum1&quot; style=&quot;color: #606060&quot;&gt;   1:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #800000&quot;&gt;configSections&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum2&quot; style=&quot;color: #606060&quot;&gt;   2:&lt;/span&gt; ...&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum3&quot; style=&quot;color: #606060&quot;&gt;   3:&lt;/span&gt;         &lt;span style=&quot;color: #0000ff&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #800000&quot;&gt;sectionGroup&lt;/span&gt; &lt;span style=&quot;color: #ff0000&quot;&gt;name&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;=&quot;episerverModules&quot;&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;&amp;gt;&lt;/span&gt;            &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum4&quot; style=&quot;color: #606060&quot;&gt;   4:&lt;/span&gt;             &lt;span style=&quot;color: #0000ff&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #800000&quot;&gt;section&lt;/span&gt; &lt;span style=&quot;color: #ff0000&quot;&gt;name&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;=&quot;episerver.FileManager&quot;&lt;/span&gt; &lt;span style=&quot;color: #ff0000&quot;&gt;type&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;=&quot;EPiServer.Demo.FileManager.Configuration.FileManagerSection, EPiServer.Demo.FileManager&quot;&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;/&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum5&quot; style=&quot;color: #606060&quot;&gt;   5:&lt;/span&gt;         &lt;span style=&quot;color: #0000ff&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span style=&quot;color: #800000&quot;&gt;sectionGroup&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum6&quot; style=&quot;color: #606060&quot;&gt;   6:&lt;/span&gt; ...&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;div class=&quot;csharpcode&quot; id=&quot;codeSnippet&quot;&gt;&lt;pre class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;&lt;pre class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;div id=&quot;codeSnippetWrapper&quot; style=&quot;border-right: silver 1px solid; padding-right: 4px; border-top: silver 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: silver 1px solid; width: 83.25%; cursor: text; direction: ltr; max-height: 200px; line-height: 12pt; padding-top: 4px; border-bottom: silver 1px solid; font-family: &#39;Courier New&#39;, courier, monospace; height: 86px; background-color: #f4f4f4; text-align: left&quot;&gt;
&lt;div id=&quot;codeSnippet&quot; style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum1&quot; style=&quot;color: #606060&quot;&gt;   1:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #800000&quot;&gt;episerverModules&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;&amp;gt;&lt;/span&gt;       &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum2&quot; style=&quot;color: #606060&quot;&gt;   2:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #800000&quot;&gt;episerver.FileManager&lt;/span&gt; configSource=&quot;Templates\FileManager\views.config&quot; &lt;span style=&quot;color: #0000ff&quot;&gt;/&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum3&quot; style=&quot;color: #606060&quot;&gt;   3:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;&amp;lt;/&lt;/span&gt;&lt;span style=&quot;color: #800000&quot;&gt;episerverModules&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Still in web.config, but in Pages declaration, add&lt;/p&gt;
&lt;div id=&quot;codeSnippetWrapper&quot; style=&quot;border-right: silver 1px solid; padding-right: 4px; border-top: silver 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: silver 1px solid; width: 83.8%; cursor: text; direction: ltr; max-height: 200px; line-height: 12pt; padding-top: 4px; border-bottom: silver 1px solid; font-family: &#39;Courier New&#39;, courier, monospace; height: 134px; background-color: #f4f4f4; text-align: left&quot;&gt;
&lt;div id=&quot;codeSnippet&quot; style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum1&quot; style=&quot;color: #606060&quot;&gt;   1:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #800000&quot;&gt;pages&lt;/span&gt; &lt;span style=&quot;color: #ff0000&quot;&gt;validateRequest&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;=&quot;false&quot;&lt;/span&gt; &lt;span style=&quot;color: #ff0000&quot;&gt;enableEventValidation&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;=&quot;false&quot;&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum2&quot; style=&quot;color: #606060&quot;&gt;   2:&lt;/span&gt;             &lt;span style=&quot;color: #0000ff&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #800000&quot;&gt;controls&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum3&quot; style=&quot;color: #606060&quot;&gt;   3:&lt;/span&gt;             ...&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum4&quot; style=&quot;color: #606060&quot;&gt;   4:&lt;/span&gt;                 &lt;span style=&quot;color: #0000ff&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #800000&quot;&gt;add&lt;/span&gt; &lt;span style=&quot;color: #ff0000&quot;&gt;tagPrefix&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;=&quot;FileManager&quot;&lt;/span&gt; &lt;span style=&quot;color: #ff0000&quot;&gt;namespace&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;=&quot;EPiServer.Demo.FileManager.WebControls&quot;&lt;/span&gt; &lt;span style=&quot;color: #ff0000&quot;&gt;assembly&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;=&quot;EPiServer.Demo.FileManager&quot;&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;/&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum5&quot; style=&quot;color: #606060&quot;&gt;   5:&lt;/span&gt;                 &lt;span style=&quot;color: #0000ff&quot;&gt;&amp;lt;&lt;/span&gt;&lt;span style=&quot;color: #800000&quot;&gt;add&lt;/span&gt; &lt;span style=&quot;color: #ff0000&quot;&gt;tagPrefix&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;=&quot;EPiServer&quot;&lt;/span&gt; &lt;span style=&quot;color: #ff0000&quot;&gt;namespace&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;=&quot;EPiServer.Templates.RelatePlus.Classes&quot;&lt;/span&gt; &lt;span style=&quot;color: #ff0000&quot;&gt;assembly&lt;/span&gt;&lt;span style=&quot;color: #0000ff&quot;&gt;=&quot;EPiServer.Templates.RelatePlus&quot;&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;/&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum6&quot; style=&quot;color: #606060&quot;&gt;   6:&lt;/span&gt;             ...&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I choose to copy the EPiCheckBox class and changed the namespace to EPiServer.Templates.RelatePlus.Classes.&lt;/p&gt;
&lt;p&gt;EPiServer Blog uploads its files into Global Files folder if not reconfigured in web.config. There it creates a xmlrpc folder and from there the tree structure is; PageID, Year, Month, Day.&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;/link/136e3e2941274476bb93d36112c462db.png&quot;&gt;&lt;img title=&quot;image&quot; style=&quot;border-top-width: 0px; display: inline; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px&quot; height=&quot;161&quot; alt=&quot;image&quot; src=&quot;/link/14be48f4f7644810af1a298984a8ec3a.png&quot; width=&quot;346&quot; border=&quot;0&quot; /&gt;&lt;/a&gt;&lt;/p&gt;








&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;My strategy was similar. The File Manager requests a RootFolder Path, so instead of a xmlrpc folder I defined a “ClubFiles” folder and beneath it a folder for each club based on ClubId, but I skipped the date folders. Similar to blogs which worked with PageID.&lt;/p&gt;
&lt;p&gt;The code then, &lt;/p&gt;
&lt;div id=&quot;codeSnippetWrapper&quot; style=&quot;border-right: silver 1px solid; padding-right: 4px; border-top: silver 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: silver 1px solid; width: 84.2%; cursor: text; direction: ltr; max-height: 200px; line-height: 12pt; padding-top: 4px; border-bottom: silver 1px solid; font-family: &#39;Courier New&#39;, courier, monospace; height: 210px; background-color: #f4f4f4; text-align: left&quot;&gt;
&lt;div id=&quot;codeSnippet&quot; style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum1&quot; style=&quot;color: #606060&quot;&gt;   1:&lt;/span&gt; &lt;span style=&quot;color: #008000&quot;&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum2&quot; style=&quot;color: #606060&quot;&gt;   2:&lt;/span&gt; &lt;span style=&quot;color: #008000&quot;&gt;/// Gets or sets the file folder root.&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum3&quot; style=&quot;color: #606060&quot;&gt;   3:&lt;/span&gt; &lt;span style=&quot;color: #008000&quot;&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum4&quot; style=&quot;color: #606060&quot;&gt;   4:&lt;/span&gt; &lt;span style=&quot;color: #008000&quot;&gt;/// &amp;lt;value&amp;gt;Path to root folder for files.&amp;lt;/value&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum5&quot; style=&quot;color: #606060&quot;&gt;   5:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;public&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;string&lt;/span&gt; FileFolderRoot&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum6&quot; style=&quot;color: #606060&quot;&gt;   6:&lt;/span&gt; {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum7&quot; style=&quot;color: #606060&quot;&gt;   7:&lt;/span&gt;   get&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum8&quot; style=&quot;color: #606060&quot;&gt;   8:&lt;/span&gt;   {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum9&quot; style=&quot;color: #606060&quot;&gt;   9:&lt;/span&gt;       &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (String.IsNullOrEmpty(_fileFolderRoot))&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum10&quot; style=&quot;color: #606060&quot;&gt;  10:&lt;/span&gt;       {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum11&quot; style=&quot;color: #606060&quot;&gt;  11:&lt;/span&gt;           _fileFolderRoot = GetVPPFolder();&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum12&quot; style=&quot;color: #606060&quot;&gt;  12:&lt;/span&gt;       }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum13&quot; style=&quot;color: #606060&quot;&gt;  13:&lt;/span&gt;       &lt;span style=&quot;color: #0000ff&quot;&gt;return&lt;/span&gt; _fileFolderRoot;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum14&quot; style=&quot;color: #606060&quot;&gt;  14:&lt;/span&gt;   }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum15&quot; style=&quot;color: #606060&quot;&gt;  15:&lt;/span&gt; }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum16&quot; style=&quot;color: #606060&quot;&gt;  16:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;private&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;string&lt;/span&gt; GetVPPFolder()&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum17&quot; style=&quot;color: #606060&quot;&gt;  17:&lt;/span&gt; {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum18&quot; style=&quot;color: #606060&quot;&gt;  18:&lt;/span&gt;     &lt;span style=&quot;color: #008000&quot;&gt;// stolen from how episerver.blogs handle file uploads, changed blog page id to use club id&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum19&quot; style=&quot;color: #606060&quot;&gt;  19:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;string&lt;/span&gt; path = &lt;span style=&quot;color: #006080&quot;&gt;&quot;&quot;&lt;/span&gt;;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum20&quot; style=&quot;color: #606060&quot;&gt;  20:&lt;/span&gt;     UnifiedDirectory vdir;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum21&quot; style=&quot;color: #606060&quot;&gt;  21:&lt;/span&gt;     VirtualPathUnifiedProvider provider = GetClubProvider(&lt;span style=&quot;color: #0000ff&quot;&gt;out&lt;/span&gt; vdir);&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum22&quot; style=&quot;color: #606060&quot;&gt;  22:&lt;/span&gt;&amp;nbsp; &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum23&quot; style=&quot;color: #606060&quot;&gt;  23:&lt;/span&gt;     path =&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum24&quot; style=&quot;color: #606060&quot;&gt;  24:&lt;/span&gt;         VirtualPathUtility.AppendTrailingSlash(VirtualPathUtility.Combine(vdir.VirtualPath,&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum25&quot; style=&quot;color: #606060&quot;&gt;  25:&lt;/span&gt;                                                                           Master.CurrentClub.ID.ToString()));&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum26&quot; style=&quot;color: #606060&quot;&gt;  26:&lt;/span&gt;     UnifiedDirectory clubdir = &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum27&quot; style=&quot;color: #606060&quot;&gt;  27:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (!(provider.DirectoryExists(path)))&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum28&quot; style=&quot;color: #606060&quot;&gt;  28:&lt;/span&gt;     {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum29&quot; style=&quot;color: #606060&quot;&gt;  29:&lt;/span&gt;         clubdir = ((UnifiedDirectory)vdir).CreateSubdirectory((Master.CurrentClub.ID.ToString()));&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum30&quot; style=&quot;color: #606060&quot;&gt;  30:&lt;/span&gt;     }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum31&quot; style=&quot;color: #606060&quot;&gt;  31:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;else&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum32&quot; style=&quot;color: #606060&quot;&gt;  32:&lt;/span&gt;     {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum33&quot; style=&quot;color: #606060&quot;&gt;  33:&lt;/span&gt;         clubdir = (UnifiedDirectory)provider.GetDirectory(path);&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum34&quot; style=&quot;color: #606060&quot;&gt;  34:&lt;/span&gt;     }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum35&quot; style=&quot;color: #606060&quot;&gt;  35:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;return&lt;/span&gt; clubdir.VirtualPath;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum36&quot; style=&quot;color: #606060&quot;&gt;  36:&lt;/span&gt; }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum37&quot; style=&quot;color: #606060&quot;&gt;  37:&lt;/span&gt;&amp;nbsp; &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum38&quot; style=&quot;color: #606060&quot;&gt;  38:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;private&lt;/span&gt; VirtualPathUnifiedProvider GetClubProvider(&lt;span style=&quot;color: #0000ff&quot;&gt;out&lt;/span&gt; UnifiedDirectory vdir)&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum39&quot; style=&quot;color: #606060&quot;&gt;  39:&lt;/span&gt; {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum40&quot; style=&quot;color: #606060&quot;&gt;  40:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;const&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;string&lt;/span&gt; vppProviderName = &lt;span style=&quot;color: #006080&quot;&gt;&quot;SiteGlobalFiles&quot;&lt;/span&gt;;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum41&quot; style=&quot;color: #606060&quot;&gt;  41:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;const&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;string&lt;/span&gt; clubfiles = &lt;span style=&quot;color: #006080&quot;&gt;&quot;clubFiles&quot;&lt;/span&gt;;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum42&quot; style=&quot;color: #606060&quot;&gt;  42:&lt;/span&gt;     VirtualPathUnifiedProvider provider = (VirtualPathUnifiedProvider)VirtualPathHandler.GetProvider(vppProviderName);&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum43&quot; style=&quot;color: #606060&quot;&gt;  43:&lt;/span&gt;&amp;nbsp; &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum44&quot; style=&quot;color: #606060&quot;&gt;  44:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (provider.DirectoryExists(provider.VirtualPathRoot + clubfiles))&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum45&quot; style=&quot;color: #606060&quot;&gt;  45:&lt;/span&gt;     {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum46&quot; style=&quot;color: #606060&quot;&gt;  46:&lt;/span&gt;         vdir = (UnifiedDirectory)provider.GetDirectory(provider.VirtualPathRoot + clubfiles);&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum47&quot; style=&quot;color: #606060&quot;&gt;  47:&lt;/span&gt;     }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum48&quot; style=&quot;color: #606060&quot;&gt;  48:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;else&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum49&quot; style=&quot;color: #606060&quot;&gt;  49:&lt;/span&gt;     {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum50&quot; style=&quot;color: #606060&quot;&gt;  50:&lt;/span&gt;         vdir = (UnifiedDirectory)provider.GetDirectory(provider.VirtualPathRoot);&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum51&quot; style=&quot;color: #606060&quot;&gt;  51:&lt;/span&gt;         vdir = vdir.CreateSubdirectory(clubfiles);&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum52&quot; style=&quot;color: #606060&quot;&gt;  52:&lt;/span&gt;     }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum53&quot; style=&quot;color: #606060&quot;&gt;  53:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;return&lt;/span&gt; provider;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum54&quot; style=&quot;color: #606060&quot;&gt;  54:&lt;/span&gt; }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Alright, Lets create an ClubFiles.aspx PageType in our RelatePlus project and set the MasterPageFile to ClubMasterPage. Add the RelatePlus NoClubAccess usercontrol and the File Manager webcontrol,&lt;/p&gt;
&lt;div id=&quot;codeSnippetWrapper&quot; style=&quot;border-right: silver 1px solid; padding-right: 4px; border-top: silver 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: silver 1px solid; width: 84.89%; cursor: text; direction: ltr; max-height: 200px; line-height: 12pt; padding-top: 4px; border-bottom: silver 1px solid; font-family: &#39;Courier New&#39;, courier, monospace; height: 182px; background-color: #f4f4f4; text-align: left&quot;&gt;
&lt;div id=&quot;codeSnippet&quot; style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum1&quot; style=&quot;color: #606060&quot;&gt;   1:&lt;/span&gt; &amp;lt;%@ Page Language=&lt;span style=&quot;color: #006080&quot;&gt;&quot;C#&quot;&lt;/span&gt; AutoEventWireup=&lt;span style=&quot;color: #006080&quot;&gt;&quot;false&quot;&lt;/span&gt; CodeBehind=&lt;span style=&quot;color: #006080&quot;&gt;&quot;ClubFiles.aspx.cs&quot;&lt;/span&gt; Inherits=&lt;span style=&quot;color: #006080&quot;&gt;&quot;EPiServer.Templates.RelatePlus.Pages.ClubFiles&quot;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum2&quot; style=&quot;color: #606060&quot;&gt;   2:&lt;/span&gt;     MasterPageFile=&lt;span style=&quot;color: #006080&quot;&gt;&quot;~/Templates/RelatePlus/MasterPages/ClubMasterPage.master&quot;&lt;/span&gt; %&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum3&quot; style=&quot;color: #606060&quot;&gt;   3:&lt;/span&gt;  &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum4&quot; style=&quot;color: #606060&quot;&gt;   4:&lt;/span&gt; &amp;lt;%@ MasterType VirtualPath=&lt;span style=&quot;color: #006080&quot;&gt;&quot;~/Templates/RelatePlus/MasterPages/ClubMasterPage.master&quot;&lt;/span&gt; %&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum5&quot; style=&quot;color: #606060&quot;&gt;   5:&lt;/span&gt; &amp;lt;%@ Register TagPrefix=&lt;span style=&quot;color: #006080&quot;&gt;&quot;RelatePlus&quot;&lt;/span&gt; TagName=&lt;span style=&quot;color: #006080&quot;&gt;&quot;NoClubAccess&quot;&lt;/span&gt; Src=&lt;span style=&quot;color: #006080&quot;&gt;&quot;~/Templates/RelatePlus/UserControls/ClubUserControls/NoClubAccess.ascx&quot;&lt;/span&gt; %&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum6&quot; style=&quot;color: #606060&quot;&gt;   6:&lt;/span&gt; &amp;lt;asp:Content ID=&lt;span style=&quot;color: #006080&quot;&gt;&quot;leftContent&quot;&lt;/span&gt; runat=&lt;span style=&quot;color: #006080&quot;&gt;&quot;server&quot;&lt;/span&gt; ContentPlaceHolderID=&lt;span style=&quot;color: #006080&quot;&gt;&quot;plhLeftContentArea&quot;&lt;/span&gt;&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum7&quot; style=&quot;color: #606060&quot;&gt;   7:&lt;/span&gt;     &amp;lt;RelatePlus:NoClubAccess ID=&lt;span style=&quot;color: #006080&quot;&gt;&quot;ucNoClubAccess&quot;&lt;/span&gt; Visible=&lt;span style=&quot;color: #006080&quot;&gt;&quot;false&quot;&lt;/span&gt; runat=&lt;span style=&quot;color: #006080&quot;&gt;&quot;server&quot;&lt;/span&gt; /&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum8&quot; style=&quot;color: #606060&quot;&gt;   8:&lt;/span&gt;     &amp;lt;FileManager:FileManagerControl ID=&lt;span style=&quot;color: #006080&quot;&gt;&quot;FileManagerControl&quot;&lt;/span&gt; runat=&lt;span style=&quot;color: #006080&quot;&gt;&quot;server&quot;&lt;/span&gt; RootVirtualPath=&lt;span style=&quot;color: #006080&quot;&gt;&quot;&amp;lt;%# FileFolderRoot %&amp;gt;&quot;&lt;/span&gt; /&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum9&quot; style=&quot;color: #606060&quot;&gt;   9:&lt;/span&gt; &amp;lt;/asp:Content&amp;gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;In the code behind, we add the methods described above and databind the FileManagerControl:&lt;/p&gt;
&lt;div id=&quot;codeSnippetWrapper&quot; style=&quot;border-right: silver 1px solid; padding-right: 4px; border-top: silver 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: silver 1px solid; width: 84.19%; cursor: text; direction: ltr; max-height: 200px; line-height: 12pt; padding-top: 4px; border-bottom: silver 1px solid; font-family: &#39;Courier New&#39;, courier, monospace; height: 210px; background-color: #f4f4f4; text-align: left&quot;&gt;
&lt;div id=&quot;codeSnippet&quot; style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum1&quot; style=&quot;color: #606060&quot;&gt;   1:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;protected&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;override&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;void&lt;/span&gt; OnLoad(EventArgs e)&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum2&quot; style=&quot;color: #606060&quot;&gt;   2:&lt;/span&gt; {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum3&quot; style=&quot;color: #606060&quot;&gt;   3:&lt;/span&gt;     &lt;span style=&quot;color: #008000&quot;&gt;// Call base&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum4&quot; style=&quot;color: #606060&quot;&gt;   4:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;base&lt;/span&gt;.OnLoad(e);&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum5&quot; style=&quot;color: #606060&quot;&gt;   5:&lt;/span&gt;&amp;nbsp; &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum6&quot; style=&quot;color: #606060&quot;&gt;   6:&lt;/span&gt;     &lt;span style=&quot;color: #008000&quot;&gt;// Set view options&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum7&quot; style=&quot;color: #606060&quot;&gt;   7:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (Master.IsClubAccessable)&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum8&quot; style=&quot;color: #606060&quot;&gt;   8:&lt;/span&gt;     {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum9&quot; style=&quot;color: #606060&quot;&gt;   9:&lt;/span&gt;&amp;nbsp; &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum10&quot; style=&quot;color: #606060&quot;&gt;  10:&lt;/span&gt;         &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (!IsPostBack)&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum11&quot; style=&quot;color: #606060&quot;&gt;  11:&lt;/span&gt;         {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum12&quot; style=&quot;color: #606060&quot;&gt;  12:&lt;/span&gt;             FileManagerControl.DataBind();&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum13&quot; style=&quot;color: #606060&quot;&gt;  13:&lt;/span&gt;&amp;nbsp; &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum14&quot; style=&quot;color: #606060&quot;&gt;  14:&lt;/span&gt;             &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (FileManagerControl.CurrentVirtualDirectory == &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;)&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum15&quot; style=&quot;color: #606060&quot;&gt;  15:&lt;/span&gt;             {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum16&quot; style=&quot;color: #606060&quot;&gt;  16:&lt;/span&gt;                 GetVPPFolder();&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum17&quot; style=&quot;color: #606060&quot;&gt;  17:&lt;/span&gt;             }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum18&quot; style=&quot;color: #606060&quot;&gt;  18:&lt;/span&gt;         }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum19&quot; style=&quot;color: #606060&quot;&gt;  19:&lt;/span&gt;     }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum20&quot; style=&quot;color: #606060&quot;&gt;  20:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;else&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum21&quot; style=&quot;color: #606060&quot;&gt;  21:&lt;/span&gt;     {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum22&quot; style=&quot;color: #606060&quot;&gt;  22:&lt;/span&gt;         ucNoClubAccess.Visible = &lt;span style=&quot;color: #0000ff&quot;&gt;true&lt;/span&gt;;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum23&quot; style=&quot;color: #606060&quot;&gt;  23:&lt;/span&gt;     }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum24&quot; style=&quot;color: #606060&quot;&gt;  24:&lt;/span&gt; }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;h2&gt;Fixing the Bread Crumb&lt;/h2&gt;
&lt;p&gt;The File Manager is built for EPiServer CMS Pages and the bread crumb control expects the files to be in the page’s directory, where it gets the page owner and displays the Page Name. Well this will not work for Community clubs, so we need to change it to get the Club Name of that folder.&lt;/p&gt;
&lt;p&gt;My current solution is a quick hack where it tries to Parse the Folder name, which is the club id and then get that club. Anyhow, in the usercontrol &lt;em&gt;HeadingContent&lt;/em&gt; we modify the method &lt;em&gt;AppendBreadCrumbs&lt;/em&gt; to:&lt;/p&gt;
&lt;div id=&quot;codeSnippetWrapper&quot; style=&quot;border-right: silver 1px solid; padding-right: 4px; border-top: silver 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: silver 1px solid; width: 85.17%; cursor: text; direction: ltr; max-height: 200px; line-height: 12pt; padding-top: 4px; border-bottom: silver 1px solid; font-family: &#39;Courier New&#39;, courier, monospace; height: 210px; background-color: #f4f4f4; text-align: left&quot;&gt;
&lt;div id=&quot;codeSnippet&quot; style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum1&quot; style=&quot;color: #606060&quot;&gt;   1:&lt;/span&gt; &lt;span style=&quot;color: #008000&quot;&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum2&quot; style=&quot;color: #606060&quot;&gt;   2:&lt;/span&gt; &lt;span style=&quot;color: #008000&quot;&gt;/// Appends the cookie crumb links to the control supplied as targetControl.&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum3&quot; style=&quot;color: #606060&quot;&gt;   3:&lt;/span&gt; &lt;span style=&quot;color: #008000&quot;&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum4&quot; style=&quot;color: #606060&quot;&gt;   4:&lt;/span&gt; &lt;span style=&quot;color: #008000&quot;&gt;/// &amp;lt;param name=&quot;currentDirectory&quot;&amp;gt;The current directory.&amp;lt;/param&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum5&quot; style=&quot;color: #606060&quot;&gt;   5:&lt;/span&gt; &lt;span style=&quot;color: #008000&quot;&gt;/// &amp;lt;param name=&quot;targetControl&quot;&amp;gt;The target control to append cookie crumb links to.&amp;lt;/param&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum6&quot; style=&quot;color: #606060&quot;&gt;   6:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;private&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;void&lt;/span&gt; AppendBreadCrumbs(UnifiedDirectory currentDirectory, Control targetControl)&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum7&quot; style=&quot;color: #606060&quot;&gt;   7:&lt;/span&gt; {            &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum8&quot; style=&quot;color: #606060&quot;&gt;   8:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (currentDirectory == &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt; || FileManager.RootVirtualPath == currentDirectory.VirtualPath)&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum9&quot; style=&quot;color: #606060&quot;&gt;   9:&lt;/span&gt;     {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum10&quot; style=&quot;color: #606060&quot;&gt;  10:&lt;/span&gt;         &lt;span style=&quot;color: #008000&quot;&gt;// Reset the link enumeration when we reach the topmost directory.&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum11&quot; style=&quot;color: #606060&quot;&gt;  11:&lt;/span&gt;         _linkId = 0;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum12&quot; style=&quot;color: #606060&quot;&gt;  12:&lt;/span&gt;     }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum13&quot; style=&quot;color: #606060&quot;&gt;  13:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;else&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum14&quot; style=&quot;color: #606060&quot;&gt;  14:&lt;/span&gt;     {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum15&quot; style=&quot;color: #606060&quot;&gt;  15:&lt;/span&gt;         &lt;span style=&quot;color: #008000&quot;&gt;// Append cookie crumb for the parent directory before adding for the current directory.&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum16&quot; style=&quot;color: #606060&quot;&gt;  16:&lt;/span&gt;         AppendBreadCrumbs(currentDirectory.Parent, targetControl);&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum17&quot; style=&quot;color: #606060&quot;&gt;  17:&lt;/span&gt;         Literal slash = &lt;span style=&quot;color: #0000ff&quot;&gt;new&lt;/span&gt; Literal();&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum18&quot; style=&quot;color: #606060&quot;&gt;  18:&lt;/span&gt;         slash.Text = &lt;span style=&quot;color: #006080&quot;&gt;&quot; / &quot;&lt;/span&gt;;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum19&quot; style=&quot;color: #606060&quot;&gt;  19:&lt;/span&gt;         targetControl.Controls.Add(slash);&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum20&quot; style=&quot;color: #606060&quot;&gt;  20:&lt;/span&gt;     }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum21&quot; style=&quot;color: #606060&quot;&gt;  21:&lt;/span&gt;&amp;nbsp; &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum22&quot; style=&quot;color: #606060&quot;&gt;  22:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;string&lt;/span&gt; directoryName = currentDirectory.Name;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum23&quot; style=&quot;color: #606060&quot;&gt;  23:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (currentDirectory.Parent != &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;)&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum24&quot; style=&quot;color: #606060&quot;&gt;  24:&lt;/span&gt;     {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum25&quot; style=&quot;color: #606060&quot;&gt;  25:&lt;/span&gt;         &lt;span style=&quot;color: #0000ff&quot;&gt;int&lt;/span&gt; clubID;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum26&quot; style=&quot;color: #606060&quot;&gt;  26:&lt;/span&gt;         &lt;span style=&quot;color: #008000&quot;&gt;// a hack to make it work. Will try parse all folders&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum27&quot; style=&quot;color: #606060&quot;&gt;  27:&lt;/span&gt;         &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (&lt;span style=&quot;color: #0000ff&quot;&gt;int&lt;/span&gt;.TryParse(currentDirectory.Name, &lt;span style=&quot;color: #0000ff&quot;&gt;out&lt;/span&gt; clubID))&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum28&quot; style=&quot;color: #606060&quot;&gt;  28:&lt;/span&gt;         {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum29&quot; style=&quot;color: #606060&quot;&gt;  29:&lt;/span&gt;             Club currentClub = ClubHandler.GetClub(clubID);&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum30&quot; style=&quot;color: #606060&quot;&gt;  30:&lt;/span&gt;&amp;nbsp; &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum31&quot; style=&quot;color: #606060&quot;&gt;  31:&lt;/span&gt;             &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (currentClub != &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;)&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum32&quot; style=&quot;color: #606060&quot;&gt;  32:&lt;/span&gt;             {&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum33&quot; style=&quot;color: #606060&quot;&gt;  33:&lt;/span&gt;                 directoryName = currentClub.Name;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum34&quot; style=&quot;color: #606060&quot;&gt;  34:&lt;/span&gt;             }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum35&quot; style=&quot;color: #606060&quot;&gt;  35:&lt;/span&gt;         }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum36&quot; style=&quot;color: #606060&quot;&gt;  36:&lt;/span&gt;     }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum37&quot; style=&quot;color: #606060&quot;&gt;  37:&lt;/span&gt;&amp;nbsp; &lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum38&quot; style=&quot;color: #606060&quot;&gt;  38:&lt;/span&gt;     LinkButton b = &lt;span style=&quot;color: #0000ff&quot;&gt;new&lt;/span&gt; LinkButton();&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum39&quot; style=&quot;color: #606060&quot;&gt;  39:&lt;/span&gt;     b.ID = &lt;span style=&quot;color: #006080&quot;&gt;&quot;link&quot;&lt;/span&gt; + _linkId++;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum40&quot; style=&quot;color: #606060&quot;&gt;  40:&lt;/span&gt;     b.Text = directoryName;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum41&quot; style=&quot;color: #606060&quot;&gt;  41:&lt;/span&gt;     b.CommandArgument = currentDirectory.VirtualPath;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum42&quot; style=&quot;color: #606060&quot;&gt;  42:&lt;/span&gt;     b.CommandName = FileManagerCommandName.SelectFolder;&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum43&quot; style=&quot;color: #606060&quot;&gt;  43:&lt;/span&gt;     b.Command += &lt;span style=&quot;color: #0000ff&quot;&gt;new&lt;/span&gt; CommandEventHandler(RaiseCommand);&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum44&quot; style=&quot;color: #606060&quot;&gt;  44:&lt;/span&gt;     targetControl.Controls.Add(b);&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot; class=&quot;language-csharp&quot;&gt;&lt;code&gt;&lt;span id=&quot;lnum45&quot; style=&quot;color: #606060&quot;&gt;  45:&lt;/span&gt; }&lt;/code&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Then the “final” solution looks like this,&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;/link/c4f35697040848788f52042f6d5003f1.png&quot;&gt;&lt;img title=&quot;image&quot; style=&quot;border-top-width: 0px; display: inline; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px&quot; height=&quot;484&quot; alt=&quot;image&quot; src=&quot;/link/b55310e4e02b4d20bccf2fa1126eb0ca.png&quot; width=&quot;426&quot; border=&quot;0&quot; /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;And in Admin mode, File Management: &lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;/link/315ad7f5a83f4c3e99e53e2849e49d17.png&quot;&gt;&lt;img title=&quot;image&quot; style=&quot;border-top-width: 0px; display: inline; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px&quot; height=&quot;288&quot; alt=&quot;image&quot; src=&quot;/link/353ae31edb83455c9481e5fdd4d5dad4.png&quot; width=&quot;644&quot; border=&quot;0&quot; /&gt;&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Then you’re done. Now check in your code, get a cup of coffee and let the GUI dude fix the layout stuff.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;

&lt;p&gt;Something that I haven’t done yet but I should is to create my own Virtual path provider. Inherit from&lt;em&gt;&amp;nbsp;&lt;/em&gt;EPiServers &lt;em&gt;VPP, &lt;/em&gt;override the &lt;em&gt;QueryAccess&lt;/em&gt; method and check that the access rights of the files match the current users club access rights. Might be a different blog post.&lt;/p&gt;
&lt;p&gt;By the way, I haven’t tested this on live site yet and might have forgotten something. Comments and feedback is appreciated.&lt;/p&gt;</id><updated>2009-10-02T18:15:09.0000000Z</updated><summary type="html">Blog post</summary></entry> <entry><title>Do you want Community features on your CMS pages? PageEntity to the rescue</title><link href="https://world.optimizely.com/blogs/Per-Hemmingson/Dates/2009/6/Do-you-want-Community-features-on-your-CMS-pages-PageEntity-to-the-rescue/" /><id>&lt;p&gt;For a while now you have been able to rate articles and blog posts, as well as see most viewed, most popular and a Tag Cloud for each. These items are standard CMS pages but with a custom made EPiServer Community Module hooked up, aka PageEntity.&lt;/p&gt; &lt;p&gt;However, this blog post will not go into detail on how to create a community module cause it is better explained in detail in &lt;a href=&quot;http://world.episerver.com/en/System/Users-and-profiles/Community-Profile-Card/?encryptedcurrentid=tZ//ufsbdy/9yHKibdLcNM8ftw5ARvYXOnXXMnYJ6mA%3d&quot; target=&quot;_blank&quot;&gt;Joel Abrahamsson&lt;/a&gt;’s &lt;a href=&quot;http://world.episerver.com/en/Articles/Items/Creating-a-Custom-EPiServer-Community-Module---Part-One/&quot; target=&quot;_blank&quot;&gt;article&lt;/a&gt; series on the subject. Read it first and you will better understand this PageEntity module.&lt;/p&gt; &lt;p&gt;We started of simple and created the PageEntity class for all our objects, and then we could pass in what type of page it is (article, blog, standard, etc) to the constructor. Well we created PageEntityTypes enum to handle it (the observant one can see that not all of them are implemented live yet) &lt;/p&gt; &lt;div id=&quot;codeSnippetWrapper&quot;&gt; &lt;div id=&quot;codeSnippet&quot; style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum1&quot; style=&quot;color: #606060&quot;&gt;   1:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;public&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;enum&lt;/span&gt; PageEntityTypes&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum2&quot; style=&quot;color: #606060&quot;&gt;   2:&lt;/span&gt; {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum3&quot; style=&quot;color: #606060&quot;&gt;   3:&lt;/span&gt;         Undefined = 0,&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum4&quot; style=&quot;color: #606060&quot;&gt;   4:&lt;/span&gt;         ForumThread = 1,&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum5&quot; style=&quot;color: #606060&quot;&gt;   5:&lt;/span&gt;         ForumPost = 2,&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum6&quot; style=&quot;color: #606060&quot;&gt;   6:&lt;/span&gt;         Article = 3,&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum7&quot; style=&quot;color: #606060&quot;&gt;   7:&lt;/span&gt;         Documentation = 4,&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum8&quot; style=&quot;color: #606060&quot;&gt;   8:&lt;/span&gt;         VideoPage = 5,&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum9&quot; style=&quot;color: #606060&quot;&gt;   9:&lt;/span&gt;         DownloadPage = 6,&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum10&quot; style=&quot;color: #606060&quot;&gt;  10:&lt;/span&gt;         FAQ = 7,&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum11&quot; style=&quot;color: #606060&quot;&gt;  11:&lt;/span&gt;         StandardPage = 8,&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum12&quot; style=&quot;color: #606060&quot;&gt;  12:&lt;/span&gt;         BlogItem = 9,&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum13&quot; style=&quot;color: #606060&quot;&gt;  13:&lt;/span&gt;         CodeSample = 10&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum14&quot; style=&quot;color: #606060&quot;&gt;  14:&lt;/span&gt; }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Then for example to Tag an existing Article page looks like this:&lt;/p&gt;
&lt;div id=&quot;codeSnippetWrapper&quot;&gt;
&lt;div id=&quot;codeSnippet&quot; style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum1&quot; style=&quot;color: #606060&quot;&gt;   1:&lt;/span&gt; &lt;span style=&quot;color: #008000&quot;&gt;// check if pageentity exists for this page, if not, create it&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum2&quot; style=&quot;color: #606060&quot;&gt;   2:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (CurrenPageEntity == &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;)&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum3&quot; style=&quot;color: #606060&quot;&gt;   3:&lt;/span&gt; {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum4&quot; style=&quot;color: #606060&quot;&gt;   4:&lt;/span&gt;     CurrenPageEntity = &lt;span style=&quot;color: #0000ff&quot;&gt;new&lt;/span&gt; PageEntity(CurrentPage.PageGuid, Enums.PageEntityTypes.Article);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum5&quot; style=&quot;color: #606060&quot;&gt;   5:&lt;/span&gt;     CurrenPageEntity.EntityTags.Add(&lt;span style=&quot;color: #0000ff&quot;&gt;new&lt;/span&gt; EntityTag(&lt;span style=&quot;color: #0000ff&quot;&gt;new&lt;/span&gt; Tag(txtTagBox.Text), &lt;span style=&quot;color: #0000ff&quot;&gt;new&lt;/span&gt; UserAuthor(writerIUser)));&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum6&quot; style=&quot;color: #606060&quot;&gt;   6:&lt;/span&gt;     CurrenPageEntity = PageEntityHandler.AddPageEntity(CurrenPageEntity);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum7&quot; style=&quot;color: #606060&quot;&gt;   7:&lt;/span&gt; }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;The code above assumes you have a PageEntity property named CurrentPageEntity.&lt;/p&gt;
&lt;p&gt;However this approach soon appeared to be not good enough. It worked for most situations except when you wanted a Tag Cloud of Article type.&lt;br /&gt;Version 0.2 was to make PageEntity class abstract and create about 9 subclasses of it to get a specific type. Below example for a EPiServer famous standard page&lt;/p&gt;
&lt;div id=&quot;codeSnippetWrapper&quot;&gt;
&lt;div id=&quot;codeSnippet&quot; style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum1&quot; style=&quot;color: #606060&quot;&gt;   1:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;public&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;class&lt;/span&gt; StandardPageEntity : PageEntity&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum2&quot; style=&quot;color: #606060&quot;&gt;   2:&lt;/span&gt; {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum3&quot; style=&quot;color: #606060&quot;&gt;   3:&lt;/span&gt;    &lt;span style=&quot;color: #0000ff&quot;&gt;public&lt;/span&gt; StandardPageEntity(Guid pageGuid, EPiServer.Common.ISite site):&lt;span style=&quot;color: #0000ff&quot;&gt;base&lt;/span&gt;(pageGuid, site, PageEntityTypes.StandardPage){}&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum4&quot; style=&quot;color: #606060&quot;&gt;   4:&lt;/span&gt;    &lt;span style=&quot;color: #0000ff&quot;&gt;public&lt;/span&gt; StandardPageEntity(&lt;span style=&quot;color: #0000ff&quot;&gt;int&lt;/span&gt; id, &lt;span style=&quot;color: #0000ff&quot;&gt;int&lt;/span&gt; siteId, Guid pageGuid) : &lt;span style=&quot;color: #0000ff&quot;&gt;base&lt;/span&gt;(id, siteId, pageGuid, PageEntityTypes.StandardPage) { }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum5&quot; style=&quot;color: #606060&quot;&gt;   5:&lt;/span&gt; }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The CurrentPageEntity moved to a base class to handle all pages entity types, it got a little large for a property… &lt;/p&gt;
&lt;div id=&quot;codeSnippetWrapper&quot;&gt;
&lt;div id=&quot;codeSnippet&quot; style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum1&quot; style=&quot;color: #606060&quot;&gt;   1:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;public&lt;/span&gt; PageEntity CurrentPageEntity&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum2&quot; style=&quot;color: #606060&quot;&gt;   2:&lt;/span&gt; {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum3&quot; style=&quot;color: #606060&quot;&gt;   3:&lt;/span&gt;     get&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum4&quot; style=&quot;color: #606060&quot;&gt;   4:&lt;/span&gt;     {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum5&quot; style=&quot;color: #606060&quot;&gt;   5:&lt;/span&gt;         &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; ((_currentPageEntity == &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt; &amp;amp;&amp;amp; ViewState[&lt;span style=&quot;color: #006080&quot;&gt;&quot;currentPageEntityGUID&quot;&lt;/span&gt;] != &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;))&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum6&quot; style=&quot;color: #606060&quot;&gt;   6:&lt;/span&gt;         {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum7&quot; style=&quot;color: #606060&quot;&gt;   7:&lt;/span&gt;             _currentPageEntity = PageEntityHandler.GetPageEntityByGUID((Guid)ViewState[&lt;span style=&quot;color: #006080&quot;&gt;&quot;currentPageEntityGUID&quot;&lt;/span&gt;]);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum8&quot; style=&quot;color: #606060&quot;&gt;   8:&lt;/span&gt;         }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum9&quot; style=&quot;color: #606060&quot;&gt;   9:&lt;/span&gt;         &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum10&quot; style=&quot;color: #606060&quot;&gt;  10:&lt;/span&gt;         &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (_currentPageEntity == &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;)&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum11&quot; style=&quot;color: #606060&quot;&gt;  11:&lt;/span&gt;         {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum12&quot; style=&quot;color: #606060&quot;&gt;  12:&lt;/span&gt;             _currentPageEntity = PageEntityHandler.GetPageEntityByGUID(CurrentPage.PageGuid);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum13&quot; style=&quot;color: #606060&quot;&gt;  13:&lt;/span&gt;         }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum14&quot; style=&quot;color: #606060&quot;&gt;  14:&lt;/span&gt;&amp;nbsp; &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum15&quot; style=&quot;color: #606060&quot;&gt;  15:&lt;/span&gt;         &lt;span style=&quot;color: #008000&quot;&gt;// check that pageEntity is enabled on current page&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum16&quot; style=&quot;color: #606060&quot;&gt;  16:&lt;/span&gt;         &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (!EnableVisit || !EnableTagging || !ShowRating)&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum17&quot; style=&quot;color: #606060&quot;&gt;  17:&lt;/span&gt;         {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum18&quot; style=&quot;color: #606060&quot;&gt;  18:&lt;/span&gt;             &lt;span style=&quot;color: #0000ff&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum19&quot; style=&quot;color: #606060&quot;&gt;  19:&lt;/span&gt;         }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum20&quot; style=&quot;color: #606060&quot;&gt;  20:&lt;/span&gt;&amp;nbsp; &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum21&quot; style=&quot;color: #606060&quot;&gt;  21:&lt;/span&gt;         &lt;span style=&quot;color: #008000&quot;&gt;// check that current site has been inititalized and defined&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum22&quot; style=&quot;color: #606060&quot;&gt;  22:&lt;/span&gt;         &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt;(SiteHandler.CurrentSite == &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;)&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum23&quot; style=&quot;color: #606060&quot;&gt;  23:&lt;/span&gt;         {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum24&quot; style=&quot;color: #606060&quot;&gt;  24:&lt;/span&gt;             &lt;span style=&quot;color: #0000ff&quot;&gt;throw&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;new&lt;/span&gt; EPiServerException(&lt;span style=&quot;color: #006080&quot;&gt;&quot;Current site is null - cannot create Page Entity&quot;&lt;/span&gt;);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum25&quot; style=&quot;color: #606060&quot;&gt;  25:&lt;/span&gt;         }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum26&quot; style=&quot;color: #606060&quot;&gt;  26:&lt;/span&gt;&amp;nbsp; &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum27&quot; style=&quot;color: #606060&quot;&gt;  27:&lt;/span&gt;         &lt;span style=&quot;color: #008000&quot;&gt;// if still null create it&lt;/span&gt;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum28&quot; style=&quot;color: #606060&quot;&gt;  28:&lt;/span&gt;         &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (_currentPageEntity == &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;)&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum29&quot; style=&quot;color: #606060&quot;&gt;  29:&lt;/span&gt;         {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum30&quot; style=&quot;color: #606060&quot;&gt;  30:&lt;/span&gt;             _currentPageEntity = (PageEntity)Activator.CreateInstance(PageEntityUtils.GetPageEntityType(CurrentPage), CurrentPage.PageGuid,&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum31&quot; style=&quot;color: #606060&quot;&gt;  31:&lt;/span&gt;                                                           SiteHandler.CurrentSite);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum32&quot; style=&quot;color: #606060&quot;&gt;  32:&lt;/span&gt;             &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum33&quot; style=&quot;color: #606060&quot;&gt;  33:&lt;/span&gt;             _currentPageEntity = PageEntityHandler.AddPageEntity(_currentPageEntity);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum35&quot; style=&quot;color: #606060&quot;&gt;  35:&lt;/span&gt;         }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum36&quot; style=&quot;color: #606060&quot;&gt;  36:&lt;/span&gt;         &lt;span style=&quot;color: #0000ff&quot;&gt;return&lt;/span&gt;  _currentPageEntity;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum37&quot; style=&quot;color: #606060&quot;&gt;  37:&lt;/span&gt;     }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum38&quot; style=&quot;color: #606060&quot;&gt;  38:&lt;/span&gt;     set&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum39&quot; style=&quot;color: #606060&quot;&gt;  39:&lt;/span&gt;     {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum40&quot; style=&quot;color: #606060&quot;&gt;  40:&lt;/span&gt;         _currentPageEntity = &lt;span style=&quot;color: #0000ff&quot;&gt;value&lt;/span&gt;;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum41&quot; style=&quot;color: #606060&quot;&gt;  41:&lt;/span&gt;         ViewState[&lt;span style=&quot;color: #006080&quot;&gt;&quot;currentPageEntityGUID&quot;&lt;/span&gt;] = (&lt;span style=&quot;color: #0000ff&quot;&gt;value&lt;/span&gt; != &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;) ? (&lt;span style=&quot;color: #0000ff&quot;&gt;object&lt;/span&gt;)&lt;span style=&quot;color: #0000ff&quot;&gt;value&lt;/span&gt;.PageGUID : &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum42&quot; style=&quot;color: #606060&quot;&gt;  42:&lt;/span&gt;     }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum43&quot; style=&quot;color: #606060&quot;&gt;  43:&lt;/span&gt; }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;We wanted the website editors to enable/disable PageEntity function on parts of the site, hence the &lt;em&gt;EnableVisit, EnableTagging &lt;/em&gt;and &lt;em&gt;ShowRating&lt;/em&gt; dynamic properties above. On the &lt;a href=&quot;http://world.episerver.com/&quot;&gt;World&lt;/a&gt; we also use several community sites, therefore check of &lt;em&gt;SiteHandler.Currentsite. &lt;/em&gt;We also determined to reference all pages by PageGuid to be on the safe side.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;The method &lt;em&gt;PageEntityUtils.GetPageEntityType &lt;/em&gt;is very simple, it helps determine what type of page it is. Example for wiki page:&lt;/p&gt;
&lt;div id=&quot;codeSnippetWrapper&quot;&gt;
&lt;div id=&quot;codeSnippet&quot; style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum1&quot; style=&quot;color: #606060&quot;&gt;   1:&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;public&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;static&lt;/span&gt; Type GetPageEntityType(PageData CurrentPage)&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum2&quot; style=&quot;color: #606060&quot;&gt;   2:&lt;/span&gt; {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum3&quot; style=&quot;color: #606060&quot;&gt;   3:&lt;/span&gt;&amp;nbsp; &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum4&quot; style=&quot;color: #606060&quot;&gt;   4:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;if&lt;/span&gt; (CurrentPage.PageTypeName == &lt;span style=&quot;color: #006080&quot;&gt;&quot;[Wiki] Article&quot;&lt;/span&gt;)&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum5&quot; style=&quot;color: #606060&quot;&gt;   5:&lt;/span&gt;     {&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum6&quot; style=&quot;color: #606060&quot;&gt;   6:&lt;/span&gt;         &lt;span style=&quot;color: #0000ff&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;typeof&lt;/span&gt; (WikiArticlePageEntity);&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum7&quot; style=&quot;color: #606060&quot;&gt;   7:&lt;/span&gt;     }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum8&quot; style=&quot;color: #606060&quot;&gt;   8:&lt;/span&gt;&amp;nbsp; &lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: white; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum9&quot; style=&quot;color: #606060&quot;&gt;   9:&lt;/span&gt;     &lt;span style=&quot;color: #0000ff&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color: #0000ff&quot;&gt;null&lt;/span&gt;;&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;pre style=&quot;padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; direction: ltr; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: &#39;Courier New&#39;, courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; text-align: left; border-bottom-style: none&quot;&gt;&lt;span id=&quot;lnum10&quot; style=&quot;color: #606060&quot;&gt;  10:&lt;/span&gt; }&lt;/pre&gt;&lt;!--CRLF--&gt;&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;You have to handle deleted pages with a PageEntity reference. Our choice was to create a httpmodule (&lt;em&gt;PageEntityEventHandler.cs&lt;/em&gt;) and remove it.&lt;/p&gt;
&lt;p&gt;Integrate it is quite easily, I added it to a Relate+ /wikiX site in about 10 minutes.&amp;nbsp; Which you can see on the updated &lt;a href=&quot;http://episerverwiki.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=28560&quot;&gt;wikiX&lt;/a&gt; for &lt;a href=&quot;http://world.episerver.com/en/Articles/Items/EPiServer-Relate-The-Best-of-Both-Worlds/&quot;&gt;Relate&lt;/a&gt;+ version on codeplex. &lt;br /&gt;in the supplied &lt;/p&gt;
&lt;p&gt;file you see how we added it to the &lt;a href=&quot;http://www.codeplex.com/EPiServerWiki&quot; target=&quot;_blank&quot;&gt;WikiX&lt;/a&gt; article page.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Add the cs. files to your project, 
&lt;/li&gt;&lt;li&gt;Run the supplied sql script to create tblPageEntity and the stored procedures 
&lt;/li&gt;&lt;li&gt;Then modify your code to create PageEntity of your choice. (Update *enum, *subclasses, *utils) &lt;/li&gt;&lt;/ul&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Feedback and suggestions for improvement is welcome. Remember this module is not supported by EPiServer. It just demonstrates how to apply EPiServer Community features on CMS pages.&lt;br /&gt;In a not so distant future release of the community you will also be able to comment your page entities. Sweet?!&lt;/p&gt;
&lt;p&gt;Cudos to &lt;a href=&quot;http://world.episerver.com/en/System/Users-and-profiles/Community-Profile-Card/?encryptedcurrentid=Ta6z87620Kk%3d&quot; target=&quot;_blank&quot;&gt;greger&lt;/a&gt; and &lt;a href=&quot;http://world.episerver.com/en/System/Users-and-profiles/Community-Profile-Card/?encryptedcurrentid=j7C%2bIwDi%2bbs%3d&quot; target=&quot;_blank&quot;&gt;erik&lt;/a&gt; who was involved in creating the PageEntity.&lt;/p&gt;
&lt;p&gt;
&lt;/p&gt;&lt;div class=&quot;wlWriterEditableSmartContent&quot; id=&quot;scid:fb3a1972-4489-4e52-abe7-25a00bb07fdf:6b3d4f69-df6e-40f8-8951-a715023d7105&quot; style=&quot;padding-right: 0px; display: inline; padding-left: 0px; float: none; padding-bottom: 0px; margin: 0px; padding-top: 0px&quot;&gt;&lt;p&gt; &lt;a href=&quot;/link/f21331702c08481dbc0bda6a737791a6.zip&quot; target=&quot;_blank&quot;&gt;PageEntity.zip&lt;/a&gt;&lt;/p&gt;&lt;/div&gt;</id><updated>2009-06-16T15:17:43.6470000Z</updated><summary type="html">Blog post</summary></entry> <entry><title>EPiServerDay 2009 - Will there be singing?</title><link href="https://world.optimizely.com/blogs/Per-Hemmingson/Dates/2009/3/EPiServerDay-2009---Will-there-be-singing/" /><id>&lt;p&gt;It is soon time for &lt;a href=&quot;http://www.episerver.com/en/Events/Upcoming_Events/EPiServer-Day-2009/&quot; target=&quot;_blank&quot;&gt;EPiServer day&lt;/a&gt; and many of my colleagues are working hard to prepare their presentations and code samples. I think will see some real cool and useful code demos.&lt;/p&gt; &lt;p&gt;Anyhow, stumbled on this good blog post which might be useful, its about presentation techniques, and point 7 is one I think everyone should use. :-)&lt;/p&gt; &lt;p&gt;&lt;a title=&quot;http://blog.nerdplusart.com/archives/tips-for-presenting&quot; href=&quot;http://blog.nerdplusart.com/archives/tips-for-presenting&quot;&gt;http://blog.nerdplusart.com/archives/tips-for-presenting&lt;/a&gt;&lt;/p&gt; &lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;Also, If you can read this it means our update on world.episerver.com went ok tonight where we have remaked the blog area, did some bug fixes and tweaked the layout a bit. If you find any errors please let us know at &lt;a href=&quot;mailto:epw@episerver.com&quot;&gt;epw@episerver.com&lt;/a&gt;.&lt;/p&gt; &lt;p&gt;Thanks and hope I see you at the EPiServer Day, I will be room host and help filming some presentations.&lt;/p&gt; &lt;p&gt;Per&lt;/p&gt;</id><updated>2009-03-05T20:24:21.5770000Z</updated><summary type="html">Blog post</summary></entry> <entry><title>EPiServer CMS R2 Upgrade experience</title><link href="https://world.optimizely.com/blogs/Per-Hemmingson/Dates/2008/10/EPiServer-CMS-R2-Upgrade-experience/" /><id>&lt;p&gt;Early this morning we took on the task of upgrading &lt;a href=&quot;http://world.episerver.com&quot;&gt;http://world.episerver.com&lt;/a&gt; to latest release of EPiServer CMS R2, with the motto that we should run our own web sites on the latest release of EPiServer CMS. Usually people in the community wait untill the first Hotfix or Service Pack is relased before considering an upgrade, I like that strategy too. &lt;br /&gt;But I&#39;m damned if I do and doesn&#39;t get paid if I don&#39;t... :-)&lt;/p&gt; &lt;p&gt;Joking aside, I thought I share some experiences. There are several &lt;a href=&quot;http://world.episerver.com/en/Documentation/Items/Release-Notes/EPiServer-CMS-5-R2---Release-Notes/Breaking-Changes/&quot; target=&quot;_blank&quot;&gt;breaking changes&lt;/a&gt;, and this time it breaks! From breaking changes document:&lt;/p&gt; &lt;ul&gt; &lt;li&gt;DataFactory.GetPage method does no longer give an Unauthorized Exception when loading an page that the current user does not have access to.&lt;/li&gt; &lt;li&gt;EPiServer.Core.IPageStore has been removed.&lt;/li&gt; &lt;li&gt;EPiServer.DataFactory no longer implement EPiServer.Core.IPageStore, EPiServer.Core.IPageStoreStatistics.&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;A long story short; You have a problem if you are using EPiServer.Security.AccessLevel in your GetPage() methods. For example &lt;em&gt;DataFactory.Instance.GetPage(blogStart.ParentLink, AccessLevel.NoAccess);&lt;br /&gt;&lt;/em&gt;This will give a &quot;method not found exception&quot;. So before doing the actual upgrade you need a plan.&lt;/p&gt; &lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;h2&gt;Test&lt;/h2&gt; &lt;p&gt;Plan for worst case scenario and how to deal with it. If there is an error in the upgrade process make sure you can rollback, Don&#39;t put all eggs in one basket.&lt;/p&gt; &lt;p&gt;Be prepared is the road to sucess, and test is the key. Have as identical copy as possible of your live web site. Install the new Installation manager and do a test upgrade. Usually the upgrade is done in 5 sec without problem.&lt;/p&gt; &lt;h3&gt;Create a checklist&lt;/h3&gt; &lt;p&gt;I made a small checklist with all the major components that we have at the episerverworld web site, &lt;/p&gt; &lt;ul&gt; &lt;li&gt;Forum (original from demo templates, then customized by Research)  &lt;/li&gt;&lt;li&gt;Blog (from demo templates)  &lt;/li&gt;&lt;li&gt;download,  &lt;/li&gt;&lt;li&gt;Developer support form and webservices,  &lt;/li&gt;&lt;li&gt;CRM connector  &lt;/li&gt;&lt;li&gt;Custom Scheduled jobs  &lt;/li&gt;&lt;li&gt;Buglist  &lt;/li&gt;&lt;li&gt;External modules  &lt;/li&gt;&lt;li&gt;etc. &lt;/li&gt;&lt;/ul&gt; &lt;p&gt;Then test the functionallity of your web site and check of that your components work. &lt;br /&gt;We had to recompile Blog and Forum eventhandlers, blog syndication scheduled job among other things due to the breaking change in IPageStore.GetPage(). &lt;br /&gt;There were a few external modules from EPiMore Partners that we had to remove untill they are R2 compatible. We also use EPiServer.Blog.dll from the demo templates which is not yet R2 ready. It will be released soon as I wrote in the &lt;a href=&quot;/link/5fd4372a439c450e8fa16e829df35120.aspx?epslanguage=en&quot; target=&quot;_blank&quot;&gt;developer forum&lt;/a&gt;, however I&#39;m fortune to have access to the source code so in this case I could just check out and recompile needed assemblies.&lt;/p&gt; &lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;h2&gt;The actual upgrade&lt;/h2&gt; &lt;p&gt;I usually do not like reading documents like &lt;a href=&quot;http://world.episerver.com/en/Documentation/Items/Installation-Instructions/EPiServer-CMS/EPiServer-CMS-5-R2-Installation-Instructions/&quot; target=&quot;_blank&quot;&gt;installation instructions&lt;/a&gt;, &lt;a href=&quot;http://world.episerver.com/en/Documentation/Items/Tech-Notes/EPiServer-CMS-5/EPiServer-CMS-5-R2/System-Requirements---EPiServer-CMS-5-R2/&quot; target=&quot;_blank&quot;&gt;system requirements&lt;/a&gt; and breaking changes. I think I&#39;ll manage anyway, well this morning I was doomed.&lt;/p&gt; &lt;p&gt;First of, you need .net 3.5 SP1 for the new manager to install. That will take about 10 minutes. A nice coffee break. &lt;br /&gt;Then you can install the manager. I choosed to install the necessary application files and then restart the server (I had too).&lt;/p&gt; &lt;p&gt;Finally now to upgrade. Start up the manager click upgrade from SP2 to R2 (where is sp3?). Found the &lt;a href=&quot;/link/e1c06c3ef7084a6c81391fcc8b1e3786.aspx?epslanguage=en&quot; target=&quot;_blank&quot;&gt;bug&lt;/a&gt; &quot;&lt;em&gt;#14916 Cannot upgrade when site is installed in different volume than the installation manager&quot;. &lt;br /&gt;&lt;/em&gt;Meaning, the website must be in the same volume as the manager. Also you cannot choose in which volume to install the manager, it will take the &quot;program files&quot; path. &lt;br /&gt;Solution, Install a new SP2 site with the &lt;em&gt;old&lt;/em&gt; manager in same volume, copy over our sitefiles and hook up the database. Then upgrade. -&amp;gt;Success! :-)&lt;/p&gt; &lt;h3&gt;Post upgrade items&lt;/h3&gt; &lt;p&gt;Open your checklist and test everything again. &lt;br /&gt;Check that your scheduled jobs are working. Since the services were moved and reinstalled. &lt;br /&gt;If you have custom things in Util or UI folder make sure they are at the new place (Virtual path folder, e.g. C:\Program Files\EPiServer\CMS\5.2.375.7\application\UI).&lt;/p&gt; &lt;p&gt;If you want you can clean up your bin folder from obsolete episerver assemblis as well the redirects in web.config&lt;/p&gt; &lt;ul&gt; &lt;li&gt;EPiServer.WebParts.dll  &lt;/li&gt;&lt;li&gt;EPiServer.Workflows.UI.dll  &lt;/li&gt;&lt;li&gt;EPiServer.ContentChannelService.dll  &lt;/li&gt;&lt;li&gt;EPiServer.SchedulerSvc &lt;/li&gt;&lt;/ul&gt; &lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;h2&gt;Conclusion&lt;/h2&gt; &lt;p&gt;Despite the breaking changes the development team has done a great job with this release and the new installer. There are several benefits of upgrading your site to the second editon of EPiServer CMS 5. New functionallity described in articles by &lt;a href=&quot;http://world.episerver.com/en/Articles/Items/EPiServer-CMS-R2---Features/&quot; target=&quot;_blank&quot;&gt;Roger Wirz&lt;/a&gt; and &lt;a href=&quot;http://world.episerver.com/en/Articles/Items/New-functionality-for-Editors/&quot; target=&quot;_blank&quot;&gt;Lena Spegel&lt;/a&gt;, as well as several &lt;a href=&quot;http://world.episerver.com/en/Blogs/&quot; target=&quot;_blank&quot;&gt;blog posts&lt;/a&gt; on the subject.&lt;/p&gt; &lt;p&gt;Just don&#39;t take the upgrade lightly, its more work and changes than upgrading between service packs.&lt;/p&gt;</id><updated>2008-10-01T09:01:23.0000000Z</updated><summary type="html">Blog post</summary></entry> <entry><title>Site update - Blog syndication possible</title><link href="https://world.optimizely.com/blogs/Per-Hemmingson/Dates/2008/5/Site-update---Blog-syndication-possible/" /><id>&lt;p&gt;It&#39;s been a while since last update of EPiServer World website.&lt;/p&gt;
&lt;p&gt;The main changes are&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Blog Syndication (credits to Ruwen) &lt;/li&gt;
&lt;li&gt;Changes in Download page to handle new products &lt;/li&gt;
&lt;li&gt;and of course some bugfixes &lt;/li&gt;&lt;/ul&gt;
&lt;p&gt;If you already have a blog or if you blog at labs.episerver.com you can enter the rss or atom feed url when you create a blog, or on your &quot;My setting&quot; page. For example my RSS URL is,&lt;/p&gt;
&lt;p&gt;&lt;a title=&quot;http://www.episerverworld.com/Blogs/Per-Hemmingson/?feed=RSS&quot; href=&quot;http://world.episerver.com/Blogs/Per-Hemmingson/?feed=RSS&quot;&gt;http://world.episerver.com/Blogs/Per-Hemmingson/?feed=RSS&lt;/a&gt; &lt;br /&gt;&lt;/p&gt;
&lt;p&gt;Note. in order to enter an external feed you first need to create a blog in EPiServer World; which will be the blog URL displayed on this site. The blog syndication is a scheduled job that currently runs every hour. It is also possible to filter your blog posts on tags, e.g. enter &quot;episerver&quot; will only include the posts that you have tagged with &quot;episerver&quot;.&lt;/p&gt;
&lt;p&gt;The download page will be much more userfriendly and soon the new EPiServer Community and mail products will be up there. &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Personalization&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;If you are logged in and have not yet set any personalization in your profile, e.g. the role/title checkboxes, the forum and Faq lists on the startpage will be empty. But if you for example check the box developer you will now see the 10 latest developer posts, also if you choose any of the user categories you will also see the 10 latest user posts. If you are not logged in to EPiServer World you will see 5 posts of each dev/user. &lt;/p&gt;
&lt;p&gt;Are you an &lt;a href=&quot;http://www.episerver.com/en/Start_page/Education/Certified_EPiServer_Developer/&quot; target=&quot;_blank&quot;&gt;EPiServer Certified Developer&lt;/a&gt; and it does not show on your profile? The reason could be that you have changed company, contact us if so and we will fix our infomation about you. Or you took the test over 2 years ago. The certification is valid for 2 years, but on the upcomming &lt;a href=&quot;http://www.episerver.com/en/Start_page/NewsEvents/EPiServer_Events/Upcoming_Events/EPiServer-Developer-Summit-May-30-2008/&quot; target=&quot;_blank&quot;&gt;Developer summit&lt;/a&gt; you can take the new EPiServer CMS 5 Certification for a bargin of 500 SEK.&lt;/p&gt;
&lt;p&gt;Finally a tip from my collegue &lt;a href=&quot;http://world.episerver.com/System/Users-and-profiles/Community-Profile-Card/?currentid=epn&quot; target=&quot;_blank&quot;&gt;Eric&lt;/a&gt; to you who want to get notified on your forum posts, use the RSS feed &quot;RSS for this page&quot;. Mail notifications is a hassle.&lt;/p&gt;</id><updated>2008-05-16T17:05:00.0000000Z</updated><summary type="html">Blog post</summary></entry> <entry><title>IE8</title><link href="https://world.optimizely.com/blogs/Per-Hemmingson/Dates/2008/3/IE8/" /><id>&lt;p&gt;Well I hoped this seminar, &quot;Developing cutting-edge web applications with IE8&quot; would be about new features&amp;nbsp; web slices and activities in IE8. Well it wasn&#39;t. I should have read the description online.. &lt;/p&gt;
&lt;p&gt;My colleague Eric went to some IE8 seminars too so read his blog posts also if you want to learn more.&lt;/p&gt;
&lt;p&gt;What was presented was that Microsoft likes Firebug and has implemented similar thing in IE8, now integrated into the browser. &lt;/p&gt;
&lt;p&gt;Its nice that you now can debug HTML, CSS and JavaScript in IE8 and that it supports breakpoints and other expected debugging features. It will be interesting to see the final release of IE8... &lt;/p&gt;
&lt;p&gt;Other New things in IE8 is that it supports Navigating an Ajax page, you have 10mb local data storage to improve performance and you can check if you&#39;re online or offline and save your data to name a few.. &lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;-- Per&lt;/p&gt;</id><updated>2008-03-08T12:55:00.0000000Z</updated><summary type="html">Blog post</summary></entry> <entry><title>Databinding in asp.net 3.5</title><link href="https://world.optimizely.com/blogs/Per-Hemmingson/Dates/2008/3/Databinding-in-aspnet-35/" /><id>&lt;p&gt;MIX08 seminar &quot;Bring your data to life with WPF&quot;. &lt;/p&gt;
&lt;p&gt;Anson Tsao from Microsoft talk about how to databind in Windows Presentation foundation and what&#39;s new in Asp.net 3.5 as well as a changing user interface during and after development and how to adapt to that.&lt;/p&gt;
&lt;p&gt;First of, what is databinding?&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Target: Dependent Property &lt;/li&gt;
&lt;li&gt;Source: any public property (CLR and WPF properties)&lt;/li&gt;&lt;/ul&gt;
&lt;p&gt;In WPF you can now databind to other properties, e.g. opacity, rotation etc. The demo was pretty basic and already well known to all that has already used WPF. Anyhow, I found it useful and it showed you can do simple neat things with databinding and some layout skills (..) to your web app. You can watch it online at &lt;a title=&quot;http://sessions.visitmix.com/&quot; href=&quot;http://sessions.visitmix.com/&quot;&gt;http://sessions.visitmix.com/&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Summarized up, what&#39;s new in asp.net 3.5&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;New debugging Mechanism &lt;/li&gt;
&lt;li&gt;Support for IdataErrorInfo &lt;/li&gt;
&lt;li&gt;Alternative syntax for Datavalidation &lt;/li&gt;
&lt;li&gt;and Linq support&lt;/li&gt;&lt;/ul&gt;
&lt;p&gt;Happy Binding, &lt;/p&gt;
&lt;p&gt;Per&lt;/p&gt;</id><updated>2008-03-08T12:54:00.0000000Z</updated><summary type="html">Blog post</summary></entry> <entry><title>Basic Ajax 101 in VS 2008</title><link href="https://world.optimizely.com/blogs/Per-Hemmingson/Dates/2008/3/Basic-Ajax-101-in-VS-2008/" /><id>&lt;p&gt;I just attended the seminar &quot;Building Great AJAX Applications from Scratch Using ASP.NET 3.5 and Visual Studio 2008&quot;. &lt;/p&gt;
&lt;p&gt;It was a great seminar showing how simple it is how to use Ajax, linq and asp.net 3.5 in Visual Studio 2008. &lt;/p&gt;
&lt;p&gt;Brad Abrams blog post shows the entire code sample he did which is also available to download. The seminar will also be available in Video at &lt;a title=&quot;http://sessions.visitmix.com/&quot; href=&quot;http://sessions.visitmix.com/&quot;&gt;http://sessions.visitmix.com/&lt;/a&gt;. So if you want to learn about new features in asp.net 3.5, Ajax, and linq read his &lt;a href=&quot;http://blogs.msdn.com/brada/archive/2008/03/06/mix08-session-overview-building-great-ajax-applications-from-scratch-using-asp-net-3-5-and-visual-studio-2008.aspx&quot; target=&quot;_blank&quot;&gt;blog&lt;/a&gt; it is very easy to understand and follow. &lt;/p&gt;
&lt;p&gt;He covers new controls in .net 3.5; Listview and Datapager, and also the Ajax controls; UpdatePanel and scriptmanager. And lastly client side JavaScript methods. One new neat thing in VS 2008 is that you can easily debug your JavaScript (about time, and no more alert windows debugging), you simple use sys.debug.trace(.....) which also allows you to set breakpoints. &lt;/p&gt;
&lt;p&gt;Read more about it and try yourself ASAP at &amp;gt; &lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;http://blogs.msdn.com/brada/archive/2008/03/06/mix08-session-overview-building-great-ajax-applications-from-scratch-using-asp-net-3-5-and-visual-studio-2008.aspx&quot;&gt;http://blogs.msdn.com/brada/archive/2008/03/06/mix08-session-overview-building-great-ajax-applications-from-scratch-using-asp-net-3-5-and-visual-studio-2008.aspx&lt;/a&gt; &lt;/p&gt;
&lt;p&gt;Short example of Listview implementation stolen from Brads blog post, just to give you a hint on how easy it is;&lt;/p&gt;&lt;pre&gt;&lt;?xml:namespace prefix = asp/??&gt;&lt;asp:listview id=&quot;photoList&quot; runat=&quot;server&quot; itemplaceholderid=&quot;ph&quot; xmlns:asp=&quot;#unknown&quot;&gt;
        &lt;layouttemplate&gt;
            &lt;ul class=&quot;photolist&quot;&gt;
                &lt;asp:placeholder id=&quot;ph&quot; runat=&quot;server&quot;&gt;&lt;/asp:placeholder&gt;
            &lt;/ul&gt;
        &lt;/layouttemplate&gt;
        &lt;itemtemplate&gt;
            &lt;li&gt;
                &lt;img alt=&quot;&quot; src=&quot;Images/1.jpg&quot; /&gt;
                &lt;br /&gt;
                Eat more Cake 
           
        &lt;/li&gt;&lt;/itemtemplate&gt;
    &lt;/asp:listview&gt;&lt;/pre&gt;
&lt;p&gt;Cheers.&lt;br /&gt;Per&lt;/p&gt;</id><updated>2008-03-07T12:53:00.0000000Z</updated><summary type="html">Blog post</summary></entry> <entry><title>Mix 08 report, day 1</title><link href="https://world.optimizely.com/blogs/Per-Hemmingson/Dates/2008/3/Mix-08-report-day-1/" /><id>&lt;p&gt;Me, myself and my collegae &lt;a href=&quot;http://labs.episerver.com/en/Blogs/Eric-Pettersson/&quot; target=&quot;_blank&quot;&gt;Eric&lt;/a&gt; is currently attending Microsoft &lt;a href=&quot;http://www.visitmix.com/&quot; target=&quot;_blank&quot;&gt;Mix&lt;/a&gt; conference in Las vegas. While most things that happen in Vegas stays in vegas we&#39;ll share some interesting events.&lt;/p&gt;
&lt;p&gt;First of the day starts with keynote presentation from Ray Ozzie, &lt;a href=&quot;http://weblogs.asp.net/scottgu/default.aspx&quot; target=&quot;_blank&quot;&gt;Scott Guthrie&lt;/a&gt; and Dean Hachamovitch. &lt;/p&gt;
&lt;p&gt;They demo new IE 8 as well as a lot of cool websites build with Silverlight, &lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href=&quot;http://www.nbcolympics.com/&quot; target=&quot;_blank&quot;&gt;NBC Olympics site&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;an Aol mail client &lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://memorabilia.hardrock.com/&quot; target=&quot;_blank&quot;&gt;Hard rock cafe&lt;/a&gt; and Verigo showed a neat Deep Zoom/Sea dragon implementation &lt;/li&gt;
&lt;li&gt;and coolest site, the &lt;a href=&quot;http://www.astonmartin.com&quot;&gt;www.astonmartin.com&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt;
&lt;p&gt;Internet Explorer 8, beta 1 is available now and the talked was short and about 8 topics,&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;css 2.1 support &lt;/li&gt;
&lt;li&gt;css certification &lt;/li&gt;
&lt;li&gt;Performance &lt;/li&gt;
&lt;li&gt;HTML 5 start &lt;/li&gt;
&lt;li&gt;Developer tool &lt;/li&gt;
&lt;li&gt;Activities &lt;/li&gt;
&lt;li&gt;Web slices &lt;/li&gt;
&lt;li&gt;&lt;a href=&quot;http://www.microsoft.com/windows/products/winfamily/ie/ie8/default.mspx&quot; target=&quot;_blank&quot;&gt;Beta 1 IE8 available&lt;/a&gt; &lt;/li&gt;&lt;/ol&gt;
&lt;p&gt;To summarize alot of improvements has been implemented, and some new neat functionallity added where web slices and activities was the most interesting. I&#39;ll tried IE8 on an our episerver site, and the conclusion is that we don&#39;t support it right out of the box... &lt;/p&gt;
&lt;p&gt;The rest of the day is about &lt;a href=&quot;http://www.microsoft.com/silverlight/&quot; target=&quot;_blank&quot;&gt;Silverlight 2&lt;/a&gt;, where the beta 1 is available today for download. Interesting things to mention about silverlight 2 is there adaptive streaming which adjust to the current bandwith and causes less buffering, when for example watching videos on Youtube. I&#39;ll guess our hosting department will be happy to hear this... &lt;/p&gt;
&lt;p&gt;Otherwise Mike Harsh&#39;s seminar was interesting and you can read it from is &lt;a href=&quot;http://blogs.msdn.com/mharsh/archive/2008/03/05/slides-and-demos-from-my-mix-08-talk.aspx&quot; target=&quot;_blank&quot;&gt;blog&lt;/a&gt; and download sample&#39;s there.&lt;/p&gt;
&lt;p&gt;Now it&#39;s time to bet on red.&lt;/p&gt;
&lt;p&gt;-- Per&lt;/p&gt;</id><updated>2008-03-06T11:40:00.0000000Z</updated><summary type="html">Blog post</summary></entry></feed>