<?xml version="1.0" encoding="utf-8"?>
<feed xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xml:lang="en-us" xmlns="http://www.w3.org/2005/Atom">
  <title>RichardSoeteman.net</title>
  <link rel="alternate" type="text/html" href="http://www.richardsoeteman.net/" />
  <link rel="self" href="http://www.richardsoeteman.net/SyndicationService.asmx/GetAtom" />
  <icon>favicon.ico</icon>
  <updated>2010-07-02T10:13:38.8114588+02:00</updated>
  <author>
    <name>Richard Soeteman</name>
  </author>
  <subtitle />
  <id>http://www.richardsoeteman.net/</id>
  <generator uri="http://dasblog.info/" version="2.3.9074.18820">DasBlog</generator>
  <entry>
    <title>Compatibility issues between 4.0.x and 4.5 for back-end developers</title>
    <link rel="alternate" type="text/html" href="http://www.richardsoeteman.net/2010/07/02/CompatibilityIssuesBetween40xAnd45ForBackendDevelopers.aspx" />
    <id>http://www.richardsoeteman.net/PermaLink,guid,f5052394-bab0-4c8d-afee-6a7e2827b0e3.aspx</id>
    <published>2010-07-02T10:13:38.8114588+02:00</published>
    <updated>2010-07-02T10:13:38.8114588+02:00</updated>
    <category term="Umbraco" label="Umbraco" scheme="http://www.richardsoeteman.net/CategoryView,category,Umbraco.aspx" />
    <author>
      <name>Richard Soeteman</name>
    </author>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Now that version 4.5 of Umbraco is out you want to make sure that your packages work
in both 4.0.x and 4.5. Or is that just me? So far I’ve had two compatibility issues
</p>
        <h3>~ prefix in UmbracoPath setting
</h3>
        <p>
I’m  using the Umbraco property GlobalSettings.Path (which correspondents with
the umbracoPath setting in the web.config file) to determine the Umbraco folder. This
used to be /Umbraco, Umbraco 4.5 supports virtual folder so it’s changed to ~/umbraco.
To solve this for both 4.0.x and 4.5 you can use the ToAbsolute method of the  <a href="http://msdn.microsoft.com/en-us/library/system.web.virtualpathutility.aspx" target="_blank">VirtualPathUtility</a> class. 
The example below will convert the virtual path ~/umbraco to absolute.
</p>
        <pre>VirtualPathUtility.ToAbsolute(umbraco.GlobalSettings.Path);</pre>
        <h3>Using inline javascript in Action class breaks the complete tree
</h3>
        <p>
In Umbraco you can create classed that implement the IAction interface which gives
you the possibility to add menu options to the context menu of a tree. In previous
versions of Umbraco you could use inline JavaScript in the JSFunctionName property
to have client side functionality. In Umbraco 4.5 the clientside model is changed
and if you include direct JavaScript into the JSFunction  name the complete tree
will break. Good thing is that <a href="http://twitter.com/Shazwazza" target="_blank">Shannon
AKA @Shazwazza</a> fixed a bug in 4.5 so the JSSource property of your action class
now actually gets rendered and you can include the function here, downside is that
this isn’t the case in 4.0 and we now need to think of a way to determine if we are
in 4.0 or 4.5. For CMSImport and MemberExport I’m using a CompatibilityHelper Class
that I’ve created. On this class I have a property SupportsJQueryTree that returns
true if the CurrentVersion setting is not 4.0. 
</p>
        <pre>
          <span style="color: #808080">/// &lt;summary&gt;</span>
          <span style="color: #808080">///
This class is introduced because 4.5 is a little bit different from 4.0.x </span>
          <span style="color: #808080">///
One single place to have nasty checks if the Umbraco environment supports a feature
or not</span>
          <span style="color: #808080">/// &lt;/summary&gt;</span>
          <span style="color: #0000ff">public</span>
          <span style="color: #0000ff">static</span>
          <span style="color: #0000ff">class</span> CompatibilityHelper
{ <span style="color: #0000ff">public</span><span style="color: #0000ff">static</span><span style="color: #0000ff">bool</span> SupportsJQueryTree
{ <span style="color: #0000ff">get</span> { <span style="color: #0000ff">return</span> !GlobalSettings.CurrentVersion.StartsWith("<span style="color: #8b0000">4.0</span>");
} } }</pre>
        <p>
Now I can determine in my action if the JQueryTree is supported and render JavaScript
for that, otherwise I will render JavaScript for the old Tree. In the snippet below
you see the Implementation that I’m using in CMSImport to start an import from a node
tree
</p>
        <pre>
          <span style="color: #0000ff">public</span>
          <span style="color: #0000ff">string</span> JsFunctionName
{ <span style="color: #0000ff">get</span> { <span style="color: #0000ff">if</span> (CompatibiltyHelper.SupportsJQueryTree)
{ <span style="color: #008000">//Environment supports the new tree call Javascript
via a function</span><span style="color: #008000">//doing this with inline script
this will cause the tree to crash</span><span style="color: #0000ff">return</span> "<span style="color: #8b0000">StartWizard()</span>";
} <span style="color: #0000ff">else</span> { <span style="color: #008000">//The old
tree could not have a function in JsSource, use inline script instead.</span><span style="color: #0000ff">return</span> "<span style="color: #8b0000"> parent.right.document.location.href
= '</span>" + umbraco.GlobalSettings.Path + "<span style="color: #8b0000">/plugins/CMSImport/Pages/wizard.aspx?id='
+ nodeID; </span>"; } } } <span style="color: #0000ff">public</span><span style="color: #0000ff">string</span> JsSource
{ <span style="color: #0000ff">get</span> { <span style="color: #0000ff">if</span> (CompatibiltyHelper.SupportsJQueryTree)
{ <span style="color: #008000">//Assign a function.</span><span style="color: #0000ff">return</span> "<span style="color: #8b0000">function
StartWizard(){ parent.right.document.location.href = '</span>" + VirtualPathUtility.ToAbsolute("<span style="color: #8b0000">/plugins/CMSImport/Pages/wizard.aspx</span>")
+ "<span style="color: #8b0000">?id=' + </span></pre>
        <pre>
          <span style="color: #8b0000">UmbClientMgr.mainTree().getActionNode().nodeId ;
}</span>"; } <span style="color: #0000ff">else</span> { <span style="color: #008000">//Doesn't
work in 4.0.x</span><span style="color: #0000ff">return</span><span style="color: #0000ff">string</span>.Empty;
} } }</pre>
        <p>
This might sound like a hack and it really is a hack. But for me this works. Within
a few months just a small percentage of the Umbraco users is using 4.0, the rest is
on 4.5 and I might drop support for 4.0 then and only need to delete this CompatibilityHelper
class and delete the old 4.0.x code  
</p>
        <p>
So far these are the only compatibility issues I’ve found (I don’t use the new schema
in my packages). If I find more I will create a separate blogpost for it. Hope this
post helps you with your compatibility issues in your packages
</p>
        <img width="0" height="0" src="http://www.richardsoeteman.net/aggbug.ashx?id=f5052394-bab0-4c8d-afee-6a7e2827b0e3" />
      </div>
    </content>
  </entry>
  <entry>
    <title>MemberExport V1.0 Released</title>
    <link rel="alternate" type="text/html" href="http://www.richardsoeteman.net/2010/06/07/MemberExportV10Released.aspx" />
    <id>http://www.richardsoeteman.net/PermaLink,guid,32ced68a-03c7-4b1b-b06d-e366a6a5c7d6.aspx</id>
    <published>2010-06-07T13:42:40.5138354+02:00</published>
    <updated>2010-06-07T13:42:40.5138354+02:00</updated>
    <category term="MemberExport" label="MemberExport" scheme="http://www.richardsoeteman.net/CategoryView,category,MemberExport.aspx" />
    <category term="Package" label="Package" scheme="http://www.richardsoeteman.net/CategoryView,category,Package.aspx" />
    <category term="Umbraco" label="Umbraco" scheme="http://www.richardsoeteman.net/CategoryView,category,Umbraco.aspx" />
    <author>
      <name>Richard Soeteman</name>
    </author>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
A few weeks back <a href="http://www.richardsoeteman.net/2010/05/28/MemberExportExport5000MembersInMillisecondsInsteadOfMinutes.aspx" target="_blank">I’ve
blogged about the new MemberExport</a> package I was working on. Today I can tell
you it’s released, both the free and the Pro (commercial) version. For those who missed
the last blogpost…. MemberExport (Pro) helps you export members from your Umbraco
installation to a csv file. The Free edition is limited to export only 200 records.
With the PRO version it’s  possible to save the export options  steps for
later use . 
</p>
        <p>
          <a href="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/MemberExportV1.0Released_BAF6/screenshot_2.png">
            <img style="border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px" title="screenshot" border="0" alt="screenshot" src="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/MemberExportV1.0Released_BAF6/screenshot_thumb.png" width="772" height="562" />
          </a> 
</p>
        <h3>Free Edition
</h3>
        <p>
The free edition of MemberExport can be found on <a href="http://our.umbraco.org/projects/memberexport" target="_blank">our.umbraco.org</a>.
Please vote the project up if you used and liked it.
</p>
        <h3>Pricing
</h3>
        <p>
You can buy a single domain license of MemberExport PRO. With a single domain license
you are allowed to use  MemberExport PRO  for a single domain and all subdomains,
such as www.example.com, accept.example.com, and local.example.com. We also have a
Enterprise license available. With an Enterprise license you are allowed to install
the MemberExport PRO package on unlimited production web servers, and use it for unlimited
Umbraco instances within the Enterprise. A single domain license will be available
for  <strong>39 Euro</strong>, an enterprise license for 14<strong>9 euro.  </strong>When
you buy a license you’ll get free updates within 90 days of purchase and  free
updates for all minor releases within a major release.  For example, if you purchased
a  1.0 version of MemberExport PRO, you get free updates of all 1.x versions
through our <a href="http://memberexport.soetemansoftware.nl/clientarea.aspx" target="_blank">client
area</a>. 
</p>
        <p>
          <strong>Special 1.0 offer. </strong>When you buy the 1.0 release you’ll get a free
update to 2.x. <strong>This is a 1.0 offer only!</strong></p>
        <h3>
        </h3>
        <h3>More Info
</h3>
        <p>
For more info, download, or purchase you can check out the <a href="http://memberexport.soetemansoftware.nl/" target="_blank">MemberExport</a> website
</p>
        <img width="0" height="0" src="http://www.richardsoeteman.net/aggbug.ashx?id=32ced68a-03c7-4b1b-b06d-e366a6a5c7d6" />
      </div>
    </content>
  </entry>
  <entry>
    <title>MemberExport export 5000+ members in milliseconds instead of minutes</title>
    <link rel="alternate" type="text/html" href="http://www.richardsoeteman.net/2010/05/28/MemberExportExport5000MembersInMillisecondsInsteadOfMinutes.aspx" />
    <id>http://www.richardsoeteman.net/PermaLink,guid,05084656-c987-43b2-8b52-8814c888c239.aspx</id>
    <published>2010-05-28T16:51:58.7647854+02:00</published>
    <updated>2010-05-28T16:51:58.7647854+02:00</updated>
    <category term="MemberExport" label="MemberExport" scheme="http://www.richardsoeteman.net/CategoryView,category,MemberExport.aspx" />
    <category term="Package" label="Package" scheme="http://www.richardsoeteman.net/CategoryView,category,Package.aspx" />
    <category term="Umbraco" label="Umbraco" scheme="http://www.richardsoeteman.net/CategoryView,category,Umbraco.aspx" />
    <author>
      <name>Richard Soeteman</name>
    </author>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
For those who follow me on <a href="http://twitter.com/rsoeteman" target="_blank">twitter</a> probably
know that I’m working on a new package for <a href="http://umbraco.org/" target="_blank">Umbraco</a> that
can export Members to a csv file. Below you see the first screenshot of the package.
Basically you select the groups and fields you want to export, you specify the export
options and when you click the export button a csv file is generated on the fly which
you can download. 
</p>
        <p>
 <a href="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/MemberExportexport5000membersinmilliseco_ED24/MemberExport_5.png"><img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="MemberExport" border="0" alt="MemberExport" src="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/MemberExportexport5000membersinmilliseco_ED24/MemberExport_thumb_1.png" width="699" height="447" /></a></p>
        <p>
Two days ago I started tweeting about this because I was very happy that exporting
a few hundred members only took 2 seconds. Immediately people warned me about the
fact that I used Member.GetAll to get a list of all the members which is very slow
when you want to export more than 500 records. Thanks again for this warning guys
(also for the brain breaking sql I had to write to improve the performance ;-)). 
So I changed the Member.GetAll functionality to a custom SQL query, imported 5000
extra records  and did a performance test to see if  the modification was
a success. Guess what, the export of <strong>5000+ records</strong> only took <strong>2142
milliseconds</strong>. I think that’s a great result to end the week with.
</p>
        <h3>
        </h3>
        <p>
        </p>
        <p>
        </p>
        <h3>When will this package be available?
</h3>
        <p>
Next Monday I will send the package to a few people that  want to beta test MemberExport.
When it’s stable enough I’ll release the package. There will be two versions of the
package, a free (limited to export 200) records version and a PRO version that can
also save the export options for later use. The price for the pro version will be
39 euro (ex 19% Dutch VAT, only for Dutch customers) . 
</p>
        <p>
I hope you find the package interesting!
</p>
        <img width="0" height="0" src="http://www.richardsoeteman.net/aggbug.ashx?id=05084656-c987-43b2-8b52-8814c888c239" />
      </div>
    </content>
  </entry>
  <entry>
    <title>FieldAdapters for CMSImport</title>
    <link rel="alternate" type="text/html" href="http://www.richardsoeteman.net/2010/04/16/FieldAdaptersForCMSImport.aspx" />
    <id>http://www.richardsoeteman.net/PermaLink,guid,7e6085b3-5a80-4cda-ae85-887828ca675a.aspx</id>
    <published>2010-04-16T15:09:04.7987215+02:00</published>
    <updated>2010-04-16T15:12:09.0799715+02:00</updated>
    <category term="CMSImport" label="CMSImport" scheme="http://www.richardsoeteman.net/CategoryView,category,CMSImport.aspx" />
    <category term="Umbraco" label="Umbraco" scheme="http://www.richardsoeteman.net/CategoryView,category,Umbraco.aspx" />
    <author>
      <name>Richard Soeteman</name>
    </author>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
When I released <a href="http://www.cmsimport.com/" target="_blank">CMSImport 1.0</a> two
months ago, <a href="http://www.richardsoeteman.net/2010/02/16/CMSImportPRO103Released.aspx" target="_blank">I
briefly described the FieldAdapters feature</a> that  I was going to build for
version 1.1. Today I want to go more into detail about the FieldAdapters feature for
CMSImport. 
</p>
        <h3>The problem
</h3>
        <p>
The reason I started to think about fieldadapters was because I wanted to solve a
very common problem. As you might know Umbraco only accepts three kinds of  data;
string, integer and datetime. What happens when you try to map a boolean value to 
a yes/no Umbraco datatype? An exception is thrown.  The following screenshot
contains several products that we want to import into Umbraco.
</p>
        <p>
          <a href="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/FieldAdaptersforCMSImport_D108/products_2.png">
            <img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="products" border="0" alt="products" src="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/FieldAdaptersforCMSImport_D108/products_thumb.png" width="632" height="323" />
          </a>
        </p>
        <p>
When we’ve mapped the InStore column to a yes/no datatype the import will fail because
it can’t map the boolean value to a 0 or 1 and we will see the following ugly screen
</p>
        <p>
          <a href="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/FieldAdaptersforCMSImport_D108/errors_2.png">
            <img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="errors" border="0" alt="errors" src="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/FieldAdaptersforCMSImport_D108/errors_thumb.png" width="499" height="302" />
          </a> 
</p>
        <h3>And a FieldAdapter can fix that?
</h3>
        <p>
Yes a fieldadapter inspects the value and tries to parse it, in this case it will
try to pares a true/false value to 1/0, best to explain by exploring the source code.
The whole feature is based on the new IFieldAdapter interface. 
</p>
        <pre>
          <span style="color: #0000ff">using</span> System; <span style="color: #0000ff">namespace</span> CMSImportLibrary.Interfaces
{ <span style="color: #808080">/// &lt;summary&gt;</span><span style="color: #808080">///
Implement the IFieldAdapter interface to convert an mallformed field to a correct
type.</span><span style="color: #808080">/// &lt;/summary&gt;</span><span style="color: #0000ff">public</span><span style="color: #0000ff">interface</span> IFieldAdapter
{ <span style="color: #808080">/// &lt;summary&gt;</span><span style="color: #808080">///
Contains the GUID of the datatype we want to parse using this FieldAdapter</span><span style="color: #808080">///
&lt;/summary&gt;</span> Guid DataTypeId { <span style="color: #0000ff">get</span>;
} <span style="color: #808080">/// &lt;summary&gt;</span><span style="color: #808080">///
Parse the data </span><span style="color: #808080">/// &lt;/summary&gt;</span><span style="color: #808080">///
&lt;param name="value"&gt;The value to parse&lt;/param&gt;</span><span style="color: #808080">///
&lt;returns&gt;&lt;/returns&gt;</span><span style="color: #0000ff">object</span> Parse(<span style="color: #0000ff">object</span><span style="color: #0000ff">value</span>);
} }</pre>
        <p>
As you can see in the code snippet the interface contains the property DataTypeId.
The value needs to correspondent to the Id (GUID) of the datatype you are creating
the fieldadapter for. During the import a factory inspects the underlying datatype
of the document property, if a fieldadapter is found it will execute  the Parse
method. This will work on all Umbraco datatypes (also custom datatypes or datatypes
from third party packages) as long as you know the Id of the datatype. You can find
the id by opening the datatype in Umbraco, there you see the RenderControl .
</p>
        <p>
          <a href="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/FieldAdaptersforCMSImport_D108/truefalsedatatype_2.png">
            <img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="truefalsedatatype" border="0" alt="truefalsedatatype" src="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/FieldAdaptersforCMSImport_D108/truefalsedatatype_thumb.png" width="578" height="215" />
          </a>
        </p>
        <p>
When opening the source code of the rendercontrol you’ll see the Id of the datatype
(a GUID). Don’t worry if you can’t open the source code of the datatype i’ll add the
Id’s of all known datatypes to the documentation of CMSImport and I’ll make a free
tool that shows the Id of any datatype.
</p>
        <h3>Implementation of the BooleanFieldAdapter
</h3>
        <p>
Now enough with all the boring stuff, let’s see the fieldadapter in action. Below
you’ll see the implementation of the BooleanFieldAdapter. I’ve mapped the id of the
True/false datatype to the DataTypeId property so CMSImport knows that it needs to
call the Parse method during the mapping of a yes/no document property. In the Parse
method I simply check if the value is already in the correct format , if not it will
try to convert the value to 1 or 0 and return that , otherwise it will just return
the original value.
</p>
        <pre>
          <span style="color: #0000ff">using</span> System; <span style="color: #0000ff">using</span> CMSImportLibrary.Interfaces; <span style="color: #0000ff">namespace</span> CMSImportLibrary.FieldAdapters.DefaultFieldAdapters
{ <span style="color: #0000ff">public</span><span style="color: #0000ff">class</span> BooleanFieldAdapter
: IFieldAdapter { #region IFieldAdapter Members <span style="color: #0000ff">public</span> Guid
DataTypeId { <span style="color: #0000ff">get</span> { <span style="color: #0000ff">return</span><span style="color: #0000ff">new</span> Guid("<span style="color: #8b0000">38b352c1-e9f8-4fd8-9324-9a2eab06d97a</span>");
} } <span style="color: #0000ff">public</span><span style="color: #0000ff">object</span> Parse(<span style="color: #0000ff">object</span><span style="color: #0000ff">value</span>)
{ <span style="color: #0000ff">if</span> (!(<span style="color: #0000ff">value</span>.Equals("<span style="color: #8b0000">0</span>")
|| <span style="color: #0000ff">value</span>.Equals("<span style="color: #8b0000">1</span>")))
{ <span style="color: #0000ff">bool</span> boolValue = <span style="color: #0000ff">false</span>; <span style="color: #0000ff">if</span> (<span style="color: #0000ff">bool</span>.TryParse(<span style="color: #0000ff">value</span>.ToString(), <span style="color: #0000ff">out</span> boolValue))
{ <span style="color: #0000ff">return</span> boolValue ? 1 : 0; } } <span style="color: #0000ff">return</span><span style="color: #0000ff">value</span>;
} #endregion } }</pre>
        <p>
Now when we run the import  again it will just import the data without any errors,
just by adding a few lines of code, isn’t that powerful? 
</p>
        <h3>Beyond fixing problems
</h3>
        <p>
        </p>
        <p>
        </p>
        <p>
Now that we have this mechanism we can also use it to modify data during the import.
Let’s say we import a piece of content from an old site that contains an image tag.
This will just run fine but when you have a reference to an image on your old site
and  you delete that old site all the references to the images are dead. FieldAdapters
can help solve this issue by inspecting the text, extract the image tags, import these
images into the media library and update the image tag with a reference to the media
item. This will really help keep your site consistent. The same applies for Upload
fields.
</p>
        <h3>Will all of this be included in the free version of CMSImport also?
</h3>
        <p>
All FieldAdapters that fix errors (Like the BooleanFieldAdapter) will be included
into the free version of CMSImport. FieldAdapters that helps you updating the content
will only be included in the PRO version of CMSImport. And again you can also create
your own FieldAdapters, free for both versions. 
</p>
        <p>
This will be the major feature of the V1.1 release of CMSImport. Please let me know
what you think about this feature.
</p>
        <img width="0" height="0" src="http://www.richardsoeteman.net/aggbug.ashx?id=7e6085b3-5a80-4cda-ae85-887828ca675a" />
      </div>
    </content>
  </entry>
  <entry>
    <title>TaskScheduler package released</title>
    <link rel="alternate" type="text/html" href="http://www.richardsoeteman.net/2010/04/04/TaskSchedulerPackageReleased.aspx" />
    <id>http://www.richardsoeteman.net/PermaLink,guid,614c2da5-0922-45b0-9d8a-d1224a2de7a3.aspx</id>
    <published>2010-04-04T20:22:10.3392163+02:00</published>
    <updated>2010-04-04T20:22:10.3392163+02:00</updated>
    <category term="Package" label="Package" scheme="http://www.richardsoeteman.net/CategoryView,category,Package.aspx" />
    <category term="Umbraco" label="Umbraco" scheme="http://www.richardsoeteman.net/CategoryView,category,Umbraco.aspx" />
    <author>
      <name>Richard Soeteman</name>
    </author>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
With Taskscheduler you can schedule url's/pages to be executed on a certain date and
time. It’s a simplified version of the Windows task scheduler, build on top of the
Umbraco scheduler functionality. If you’ve used  <a href="http://www.cmsimport.com/" target="_blank">CMSImport
PRO</a>, the package should look familiar because TaskScheduler is based on the scheduled
import functionality of CMSImport PRO.  When you installed the package and browse
to the developer section you’ll notice the new Scheduled Tasks tree. From here you
can create new Scheduled tasks, or browse to existing ones. 
</p>
        <h3>Schedule a task
</h3>
        <p>
When you create a scheduled task, you’ll see the following screen. In this screen
you can configure the scheduled task. 
</p>
        <p>
          <a href="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/TaskSchedulerpackagereleased_C813/TaskScheduler_6.png">
            <img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="TaskScheduler" border="0" alt="TaskScheduler" src="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/TaskSchedulerpackagereleased_C813/TaskScheduler_thumb_2.png" width="712" height="605" />
          </a>
        </p>
        <p>
The scheduled task name contains the name of the scheduled task. This will also be
shown in the tree and you can use this in the notification email template.
</p>
        <p>
The Schedule Url contains the url that you want to execute. You can insert a full
url (<a href="http://mydemosite.com/scheduledpage.aspx">http://mydemosite.com/scheduledpage.aspx</a>),
an absolute path(/scheduledpage.aspx) or a relative path(~/scheduledpage.aspx). The
last option will come handy when you start working with Umbraco 4.1 where virtual
folders are supported. When you want to retrieve the HTTP output of the page and use
that in your notify email you can set the url output to true.
</p>
        <p>
If you want to retrieve a notification email that tells you the scheduled task has
executed you can fill in your emailaddress in the notify emailaddress field. 
</p>
        <p>
Basically you’ll have three options 
</p>
        <ul>
          <li>
Execute every week on certain days and a certain time. 
</li>
          <li>
Execute every day on a certain time 
</li>
          <li>
Execute every hour 
</li>
        </ul>
        <h3>Settings
</h3>
        <p>
Not a lot of settings to configure. Only the settings for the notification email.
You can configure the from address, the subject  and the email template. In the
email template you can use two tags. 
</p>
        <ul>
          <li>
[#Taskname]. Will be replaced with the name of the configured task 
</li>
          <li>
[#Output] . Will be replaced with the html that got returned from the page if you
had checked “Use Url output in url”. 
</li>
        </ul>
        <p>
          <a href="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/TaskSchedulerpackagereleased_C813/taskschedulersettings_2.png">
            <img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="taskschedulersettings" border="0" alt="taskschedulersettings" src="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/TaskSchedulerpackagereleased_C813/taskschedulersettings_thumb.png" width="1025" height="441" />
          </a>
        </p>
        <h3>System Requirements
</h3>
        <p>
TaskScheduler is tested on Umbraco 4.0.3.1, is compatible with .NET Framework 2.0 
and is compatible with SQL Server(Express) 2005, 2008.
</p>
        <h3>Download
</h3>
        <p>
You can <a href="http://our.umbraco.org/projects/taskscheduler" target="_blank">download
the package</a> from <a href="http://our.umbraco.org/" target="_blank">our.umbraco.org</a></p>
        <p>
As always I hope that you like the package and it’s useful for you. 
</p>
        <img width="0" height="0" src="http://www.richardsoeteman.net/aggbug.ashx?id=614c2da5-0922-45b0-9d8a-d1224a2de7a3" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Developing SiteAnalyzer</title>
    <link rel="alternate" type="text/html" href="http://www.richardsoeteman.net/2010/03/26/DevelopingSiteAnalyzer.aspx" />
    <id>http://www.richardsoeteman.net/PermaLink,guid,c744a615-af88-44f4-871d-531f66b16a85.aspx</id>
    <published>2010-03-26T23:53:02.4075563+01:00</published>
    <updated>2010-03-26T23:53:02.4075563+01:00</updated>
    <category term="SiteAnalyzer" label="SiteAnalyzer" scheme="http://www.richardsoeteman.net/CategoryView,category,SiteAnalyzer.aspx" />
    <category term="Umbraco" label="Umbraco" scheme="http://www.richardsoeteman.net/CategoryView,category,Umbraco.aspx" />
    <author>
      <name>Richard Soeteman</name>
    </author>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Apart from developing client websites,  writing a manual for CMSImport and 
developing CMSImport V1.1 I’ve started the development of SiteAnalyzer last week. 
In the coming blogposts about SiteAnalyzer I will describe the development process
of this package.
</p>
        <h3>What is SiteAnalyzer?
</h3>
        <p>
SiteAnalyzer is tool that checks published pages for broken links, broken images in
both content and Templates/ XSLT/Usercontrols. In next versions of SiteAnalyzer it
will check more and more. My goal is to check for every SEO rule which you can turn
on/off.  It will be using a plugin architecture so you can add custom rules.
SiteAnalyzer will report back pages where the rules failed to validate, like the Link
failed due a 404 etc. 
</p>
        <p>
Now I hear you think, “Tools like these already exist why develop your own?”". 
I have a few reasons for that, first I was not finished and second I think integrating
such a tool into Umbraco is better so people can maintain their site through one interface
instead of having a tool for everything. This is why the <a href="http://our.umbraco.org/projects/google-analytics-for-umbraco">Google
Analytics package for Umbraco</a> is so popular.
</p>
        <p>
Again I was not finished. The killer feature of SiteAnalyzer will be the <strong>auto
repair</strong> functionality(only for content) . Best to explain by an example. Let’s
say the content editor entered the url  “www.umbraco.org” in the Rich Text editor.
The validator will fail due a 404 page not found. The auto repair function will try
to fix the url and in this example it will convert “www.umbraco.org” to “http://www.umbraco.org/”
So instead of just reporting that a url failed to validate, it will report that it
found a link that failed and repaired it for you, which saves you a few clicks.
</p>
        <h3>
        </h3>
        <h3>Will SiteAnalyzer be open source?
</h3>
        <p>
No just as CMSImport  SiteAnalyzer comes in two editions, standard (free) and
a PRO commercial edition. The difference between standard and pro will be that the
standard edition can handle only a certain amount of pages, the Pro version can be
scheduled instead of manual start of the scan and the Pro version comes with advanced
reporting which sends you a pdf after it executed.
</p>
        <h3>When will we see a first release?
</h3>
        <p>
A first Preview release will be on our.umbraco.org in Q2,  before Codegarden.
The first preview will focus on the Standard functionality.
</p>
        <p>
The next blogpost will describe the architecture of this package.
</p>
        <img width="0" height="0" src="http://www.richardsoeteman.net/aggbug.ashx?id=c744a615-af88-44f4-871d-531f66b16a85" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Select Icons for a document type</title>
    <link rel="alternate" type="text/html" href="http://www.richardsoeteman.net/2010/03/08/SelectIconsForADocumentType.aspx" />
    <id>http://www.richardsoeteman.net/PermaLink,guid,774c6b8f-d413-4419-8d91-7ac47b59e7bc.aspx</id>
    <published>2010-03-08T13:48:25.017+01:00</published>
    <updated>2010-03-08T13:53:46.6578667+01:00</updated>
    <category term="Umbraco" label="Umbraco" scheme="http://www.richardsoeteman.net/CategoryView,category,Umbraco.aspx" />
    <author>
      <name>Richard Soeteman</name>
    </author>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Recently I’ve developed a rather large website for a customer. To make the structure
as simple as possible to understand I like to use different Icons for each document
type. I was very happy with the <a href="http://our.umbraco.org/projects/famfamfam-icons">FamFamFam
Icons</a> project from The Farm. After Installing this I got another challenge and
that was to pick the right Icon.
</p>
        <p>
          <a href="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/SelectIconsforadoctype_B7BE/iconspng_2.png">
            <img title="iconspng" style="BORDER-TOP-WIDTH: 0px; DISPLAY: inline; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px" height="523" alt="iconspng" src="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/SelectIconsforadoctype_B7BE/iconspng_thumb.png" width="481" border="0" />
          </a>  
</p>
        <p>
        </p>
        <p>
Today I started working on a new project, installed the FamFamFam Icons package again
and thought that it would be better to assign document types to the Image instead
of assigning the image to a document type. I’ve created a small Usercontrol that lists
all the icons (except for the default Umbraco sprites). Next to the Icon you find 
a dropdown with the possible documenttypes which you can select.
</p>
        <p>
          <a href="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/SelectIconsforadoctype_B7BE/selecticon_2.png">
            <img title="selecticon" style="BORDER-TOP-WIDTH: 0px; DISPLAY: inline; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; BORDER-RIGHT-WIDTH: 0px" height="463" alt="selecticon" src="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/SelectIconsforadoctype_B7BE/selecticon_thumb.png" width="703" border="0" />
          </a>
        </p>
        <p>
I did not create a package out of this. It’s working for me, but it needs some improvements
before I can add it to <a href="http://our.umbraco.org/">our.umbraco.org</a>. 
Maybe that  will never happen, so attached you find a zip file. Add the IconPickerDashboard.dll
file to your bin folder, the IconPickerDashboard.ascx to your usercontrol folder.
</p>
        <p>
Add the following section to your  the Dashboard.config file.
</p>
        <pre>
          <span style="COLOR: #0000ff">&lt;</span>
          <span style="COLOR: #800000">section</span>
          <span style="COLOR: #0000ff">&gt;</span>
          <span style="COLOR: #0000ff">&lt;</span>
          <span style="COLOR: #800000">areas</span>
          <span style="COLOR: #0000ff">&gt;</span>
          <span style="COLOR: #0000ff">&lt;</span>
          <span style="COLOR: #800000">area</span>
          <span style="COLOR: #0000ff">&gt;</span>settings<span style="COLOR: #0000ff">&lt;/</span><span style="COLOR: #800000">area</span><span style="COLOR: #0000ff">&gt;</span><span style="COLOR: #0000ff">&lt;/</span><span style="COLOR: #800000">areas</span><span style="COLOR: #0000ff">&gt;</span><span style="COLOR: #0000ff">&lt;</span><span style="COLOR: #800000">tab</span><span style="COLOR: #ff0000">caption</span>=<span style="COLOR: #0000ff">"IconPicker"</span><span style="COLOR: #0000ff">&gt;</span><span style="COLOR: #0000ff">&lt;</span><span style="COLOR: #800000">control</span><span style="COLOR: #0000ff">&gt;</span>/usercontrols/IconPickerDashboard.ascx<span style="COLOR: #0000ff">&lt;/</span><span style="COLOR: #800000">control</span><span style="COLOR: #0000ff">&gt;</span><span style="COLOR: #0000ff">&lt;/</span><span style="COLOR: #800000">tab</span><span style="COLOR: #0000ff">&gt;</span><span style="COLOR: #0000ff">&lt;/</span><span style="COLOR: #800000">section</span><span style="COLOR: #0000ff">&gt;</span></pre>
        <p>
Now browse to the settings section and select the icons you like.
</p>
        <p>
Download the zip (Requires .net 3.5).
</p>
        <div class="wlWriterEditableSmartContent" id="scid:8eb9d37f-1541-4f29-b6f4-1eea890d4876:b8d74c35-1ba0-4abe-b59b-4bd4ac2dbe38" style="PADDING-RIGHT: 0px; DISPLAY: inline; PADDING-LEFT: 0px; FLOAT: none; PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-TOP: 0px">
          <p>
          </p>
          <div>
            <a href="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/SelectIconsforadoctype_B7BE/IconPickerDashboard_1.zip" target="_blank">IconPickerDashboard.zip</a>
          </div>
          <p>
          </p>
        </div>
        <p>
Or download the source:
</p>
        <div class="wlWriterEditableSmartContent" id="scid:8eb9d37f-1541-4f29-b6f4-1eea890d4876:1a2f0475-b876-4f3a-9438-869d532a008e" style="PADDING-RIGHT: 0px; DISPLAY: inline; PADDING-LEFT: 0px; FLOAT: none; PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-TOP: 0px">
          <p>
          </p>
          <div>
            <a href="http://www.richardsoeteman.net/ct.ashx?id=774c6b8f-d413-4419-8d91-7ac47b59e7bc&amp;url=http%3a%2f%2fwww.richardsoeteman.net%2fcontent%2fbinary%2fWindowsLiveWriter%2fSelectIconsforadoctype_B7BE%2fIconPickerDashboard_source_1.zip" target="_self">IconPickerDashboard_source.zip</a>
          </div>
          <p>
          </p>
        </div>
        <img width="0" height="0" src="http://www.richardsoeteman.net/aggbug.ashx?id=774c6b8f-d413-4419-8d91-7ac47b59e7bc" />
      </div>
    </content>
  </entry>
  <entry>
    <title>CMSImport (PRO) 1.0.3 released</title>
    <link rel="alternate" type="text/html" href="http://www.richardsoeteman.net/2010/02/16/CMSImportPRO103Released.aspx" />
    <id>http://www.richardsoeteman.net/PermaLink,guid,90ffa866-c315-42be-9d32-bcf85c20e6bd.aspx</id>
    <published>2010-02-16T09:57:09.7084167+01:00</published>
    <updated>2010-02-16T09:57:09.7084167+01:00</updated>
    <category term="CMSImport" label="CMSImport" scheme="http://www.richardsoeteman.net/CategoryView,category,CMSImport.aspx" />
    <category term="Package" label="Package" scheme="http://www.richardsoeteman.net/CategoryView,category,Package.aspx" />
    <category term="UmbImport" label="UmbImport" scheme="http://www.richardsoeteman.net/CategoryView,category,UmbImport.aspx" />
    <category term="Umbraco" label="Umbraco" scheme="http://www.richardsoeteman.net/CategoryView,category,Umbraco.aspx" />
    <author>
      <name>Richard Soeteman</name>
    </author>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
I’m very pleased to announce that CMSImport 1.0.3 is released. Now I can hear you
think CMSImport? Must be a fork of the great UmbImport package. No this isn’t the
case. A few weeks back Niels (AKA @Umbraco) asked me to change the name since <a title="Umbraco" href="http://www.umbraco.org." target="_blank">Umbraco</a> HQ
got a lot of requests about this package. So now the name is CMSImport and that’s
not going to change anymore.
</p>
        <h3>CMSImport PRO
</h3>
        <p>
Finally we’ve finished our commercial edition of CMSImport.  CMSImport PRO gives
you all the options of the default package and the following extra features: 
</p>
        <ul>
          <li>
Update Content 
</li>
          <li>
Save Import Steps 
</li>
          <li>
Schedule imports for a certain time and day 
</li>
        </ul>
        <h3>Pricing
</h3>
        <p>
You can buy a single domain license of CMSImport. With a single domain license you
are allowed to use  CMSImport PRO for a single domain and all subdomains, such
as www.example.com, accept.example.com, and local.example.com. 
</p>
        <p>
We also have a Enterprise license available. With an Enterprise license you are allowed
to install the CMSImport PRO on unlimited production web servers, and use it for unlimited
Umbraco instances within the Enterprise.  
</p>
        <p>
A single domain license will be available for  <strong>99 Euro</strong>, an enterpise
license for <strong>389 euro. </strong></p>
        <p>
When you buy a license you’ll get free updates within 90 days of purchase and 
free updates for all minor releases within a major release.  For example, if
you purchased a  1.0 version of CMSImport, you get free updates of all 1.x versions
through our <a href="http://www.cmsimport.com/clientarea.aspx" target="_blank">client
area</a>. 
</p>
        <p>
          <strong>Special 1.0 offer.</strong>When you buy the 1.0 release you’ll get a free
update to 2.x. <strong>This is a 1.0 offer only!</strong></p>
        <h3>
        </h3>
        <h3>What’s more in this release?
</h3>
        <p>
Several issues are solved in this release(both in the free and Pro release):
</p>
        <ul>
          <li>
"item with the same key already added" error when using duplicate column
names 
</li>
          <li>
Automapping column names 
</li>
          <li>
The imported document creator is not always the administrator anymore. It's using
the logged in user now. When you schedule an import you can select the user that should
be used as the creator of the document 
</li>
          <li>
Special characters in CSV are now supported, we’ve changed the reader from ANSI text
to Unicode 
</li>
          <li>
Sometimes CSV replaced spaces with empty strings, this is solved now 
</li>
          <li>
With member import you can now merge any member property into the template. Simply
surround the member property with [#(property here)] 
</li>
          <li>
Using a renamed Umbraco folder. This is possible now, although it will be better to
change it after install, otherwise you have to install manually. 
</li>
          <li>
We’ve removed the limitation to allow only one DataAdapter. We are thinking to build
a DataAdapter pack which contains adapters to import from wordpress, Rss, Outlook,
excel etc. These adapters will be available for free in the Commercial Edition and
for a small fee for the Free edition. 
</li>
        </ul>
        <h3>Roadmap
</h3>
        <p>
In the 1.x version we will add the following functionality:
</p>
        <ul>
          <li>
            <strong>FieldAdapters.</strong> Sounds boring but this is a big thing. When you import
data now, sometimes the import will fail. For example if you import boolean as text
(true/false) and want to store that in a True/False field in Umbraco it will fail.
Umbraco expects that the value will be 0/1. FieldAdapters will solve this problem.
If a insert of data fails. CMSImport will check if 1 o more FieldAdapters are available
to convert the data in the right format. This will be added to version 1.1 which must
be ready before CodeGarden 2010. 
</li>
          <li>
            <strong>Dictionary Import</strong>. Need I say more? 
</li>
          <li>
            <strong>
              <b>Hierarchical </b>imports</strong>(PRO only). 
</li>
        </ul>
        <p>
In the 2.x version we will add the following functionality:
</p>
        <ul>
          <li>
            <strong>
              <b>Hierarchical </b>import support in Data Adapters</strong>. Not the same
as the 1.x Hierarchical<strong></strong>import feature ;-) 
</li>
          <li>
            <strong>Export/import definitions (PRO only)</strong>. An easy way to deploy Import
definitions 
</li>
        </ul>
        <h3>
        </h3>
        <h3>More Info
</h3>
        <p>
For more info, download, or purchase you’ll go to <a title="http://www.cmsimport.com/" href="http://www.cmsimport.com/">http://www.cmsimport.com/</a></p>
        <img width="0" height="0" src="http://www.richardsoeteman.net/aggbug.ashx?id=90ffa866-c315-42be-9d32-bcf85c20e6bd" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Package Action Contrib 1.0.4</title>
    <link rel="alternate" type="text/html" href="http://www.richardsoeteman.net/2010/02/03/PackageActionContrib104.aspx" />
    <id>http://www.richardsoeteman.net/PermaLink,guid,ca001b5a-93d9-456c-9b82-5b345d5a1b80.aspx</id>
    <published>2010-02-03T16:45:02.2646644+01:00</published>
    <updated>2010-02-03T16:46:09.3896644+01:00</updated>
    <category term="Umbraco" label="Umbraco" scheme="http://www.richardsoeteman.net/CategoryView,category,Umbraco.aspx" />
    <author>
      <name>Richard Soeteman</name>
    </author>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Just a small blogpost to announce that I’ve just made a new release of the Package
Action Contrib project. The following actions are added to the project:
</p>
        <ul>
          <li>
AddConfigurationSection 
</li>
          <li>
PermissionForApp 
</li>
          <li>
AddLanguageFileKey 
</li>
          <li>
MoveFile 
</li>
          <li>
UpdateAppTree 
</li>
        </ul>
        <p>
You can download the new release and documentation from <a href="http://packageactioncontrib.codeplex.com/" target="_blank">codeplex</a>.
I’ve also updated the WIKI page on <a title="Umbraco" href="http://our.umbraco.org/wiki/reference/packaging/package-actions/community-made-package-actions" target="_blank">our.umbraco.org</a>.
</p>
        <p>
          <br />
Many thanks to the contributors of this release, Simon Dingley, Chris Houston, Dirk
de Grave and Søren Spelling Lund for submitting their code!
</p>
        <img width="0" height="0" src="http://www.richardsoeteman.net/aggbug.ashx?id=ca001b5a-93d9-456c-9b82-5b345d5a1b80" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Create a custom macro parameter type</title>
    <link rel="alternate" type="text/html" href="http://www.richardsoeteman.net/2010/01/04/CreateACustomMacroParameterType.aspx" />
    <id>http://www.richardsoeteman.net/PermaLink,guid,24e1d561-1f6c-4411-bd62-584023d31df7.aspx</id>
    <published>2010-01-04T22:37:53.3421867+01:00</published>
    <updated>2010-01-04T22:37:53.3421867+01:00</updated>
    <category term="Umbraco" label="Umbraco" scheme="http://www.richardsoeteman.net/CategoryView,category,Umbraco.aspx" />
    <author>
      <name>Richard Soeteman</name>
    </author>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
This <a href="http://our.umbraco.org/forum/developers/extending-umbraco/6203-Add-new-parameter-types-to-Macros?p=0#comment22398" target="_blank">forum
post</a>  triggered me to share some code that I had. A while back I was building
a site which  let the customers define their own custom overviews One requirement
was that users could define the sort by property . To do this you can use the property
picker but it wasn’t friendly enough for my case so I ended up building a custom macro
parameter type. 
</p>
        <p>
To start you need to create a new class library and add references to the following
assemblies:
</p>
        <ul>
          <li>
Businesslogic 
</li>
          <li>
Cms 
</li>
          <li>
Interfaces 
</li>
          <li>
            <a title="Umbraco" href="http://www.umbraco.org." target="_blank">Umbraco</a>
          </li>
          <li>
System.web 
</li>
        </ul>
        <p>
In the example below I’ve created a class that inherits from dropdownlist. This was
the easiest way since I needed a dropdownlist and didn’t want to play with the control
tree, Now more important is that this class inherits from the <em>IMacroGuiRendering</em> Interface. 
This add two properties ShowCaption, to show the caption on the parameters tab and
more important value which holds the selected value .  
</p>
        <div class="csharpcode">
          <pre>
            <span class="lnum"> 1: </span>
            <span class="kwrd">using</span> System;</pre>
          <pre>
            <span class="lnum"> 2: </span>
            <span class="kwrd">using</span> System.Collections.Generic;</pre>
          <pre>
            <span class="lnum"> 3: </span>
            <span class="kwrd">using</span> System.Text;</pre>
          <pre>
            <span class="lnum"> 4: </span>
            <span class="kwrd">using</span> System.Web.UI.WebControls;</pre>
          <pre>
            <span class="lnum"> 5: </span>
            <span class="kwrd">using</span> umbraco.interfaces;</pre>
          <pre>
            <span class="lnum"> 6: </span> </pre>
          <pre>
            <span class="lnum"> 7: </span>
            <span class="kwrd">namespace</span> MacroRenderDemo</pre>
          <pre>
            <span class="lnum"> 8: </span>{</pre>
          <pre>
            <span class="lnum"> 9: </span>
            <span class="kwrd">public</span>
            <span class="kwrd">class</span> OrderBy
: DropDownList, IMacroGuiRendering</pre>
          <pre>
            <span class="lnum"> 10: </span> {</pre>
          <pre>
            <span class="lnum"> 11: </span>
            <span class="kwrd">protected</span>
            <span class="kwrd">override</span>
            <span class="kwrd">void</span> OnLoad(EventArgs
e)</pre>
          <pre>
            <span class="lnum"> 12: </span> {</pre>
          <pre>
            <span class="lnum"> 13: </span>
            <span class="kwrd">base</span>.OnLoad(e);</pre>
          <pre>
            <span class="lnum"> 14: </span>
            <span class="kwrd">if</span> (<span class="kwrd">this</span>.Items.Count
== 0)</pre>
          <pre>
            <span class="lnum"> 15: </span> {</pre>
          <pre>
            <span class="lnum"> 16: </span>
            <span class="kwrd">this</span>.Items.Add(<span class="kwrd">new</span> ListItem(<span class="str">"Title"</span>, <span class="str">"nodeName"</span>));</pre>
          <pre>
            <span class="lnum"> 17: </span>
            <span class="kwrd">this</span>.Items.Add(<span class="kwrd">new</span> ListItem(<span class="str">"Date"</span>, <span class="str">"createDate"</span>));</pre>
          <pre>
            <span class="lnum"> 18: </span> }</pre>
          <pre>
            <span class="lnum"> 19: </span> }</pre>
          <pre>
            <span class="lnum"> 20: </span> </pre>
          <pre>
            <span class="lnum"> 21: </span>
            <span class="preproc">#region</span> IMacroGuiRendering
Members</pre>
          <pre>
            <span class="lnum"> 22: </span> </pre>
          <pre>
            <span class="lnum"> 23: </span>
            <span class="kwrd">public</span>
            <span class="kwrd">bool</span> ShowCaption</pre>
          <pre>
            <span class="lnum"> 24: </span> {</pre>
          <pre>
            <span class="lnum"> 25: </span> get { <span class="kwrd">return</span><span class="kwrd">true</span>;
}</pre>
          <pre>
            <span class="lnum"> 26: </span> }</pre>
          <pre>
            <span class="lnum"> 27: </span> </pre>
          <pre>
            <span class="lnum"> 28: </span>
            <span class="kwrd">public</span>
            <span class="kwrd">string</span> Value</pre>
          <pre>
            <span class="lnum"> 29: </span> {</pre>
          <pre>
            <span class="lnum"> 30: </span> get</pre>
          <pre>
            <span class="lnum"> 31: </span> {</pre>
          <pre>
            <span class="lnum"> 32: </span>
            <span class="kwrd">return</span>
            <span class="kwrd">this</span>.SelectedValue;</pre>
          <pre>
            <span class="lnum"> 33: </span> }</pre>
          <pre>
            <span class="lnum"> 34: </span> set</pre>
          <pre>
            <span class="lnum"> 35: </span> {</pre>
          <pre>
            <span class="lnum"> 36: </span>
            <span class="kwrd">this</span>.SelectedValue
= <span class="kwrd">value</span>;</pre>
          <pre>
            <span class="lnum"> 37: </span> }</pre>
          <pre>
            <span class="lnum"> 38: </span> }</pre>
          <pre>
            <span class="lnum"> 39: </span> </pre>
          <pre>
            <span class="lnum"> 40: </span>
            <span class="preproc">#endregion</span>
          </pre>
          <pre>
            <span class="lnum"> 41: </span> }</pre>
          <pre>
            <span class="lnum"> 42: </span>}</pre>
        </div>
        <style type="text/css">

.csharpcode, .csharpcode pre
{
	font-size: small;
	color: black;
	font-family: consolas, "Courier New", courier, monospace;
	background-color: #ffffff;
	/*white-space: pre;*/
}
.csharpcode pre { margin: 0em; }
.csharpcode .rem { color: #008000; }
.csharpcode .kwrd { color: #0000ff; }
.csharpcode .str { color: #006080; }
.csharpcode .op { color: #0000c0; }
.csharpcode .preproc { color: #cc6633; }
.csharpcode .asp { background-color: #ffff00; }
.csharpcode .html { color: #800000; }
.csharpcode .attr { color: #ff0000; }
.csharpcode .alt 
{
	background-color: #f4f4f4;
	width: 100%;
	margin: 0em;
}
.csharpcode .lnum { color: #606060; }</style>
        <p>
When you build the project and add the binary into the bin folder of your Umbraco
site you still can’t select the new type from the parameter type list. First we need
to register the class  in the database. Below you’ll see the database table that
holds all the Macro property types.
</p>
        <p>
          <img title="dbrecords" style="border-top-width: 0px; display: inline; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="378" alt="dbrecords" src="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/Createacustommacroparametertype_1212C/dbrecords_25180f92-f0b8-4354-9f5c-704b8160735b.jpg" width="881" border="0" /> 
</p>
        <p>
It is important that you add the Assemblyname  including the namespace to the
macroPropertyTypeRenderAssembly column and add the name of your class to the 
macroPropertyTypeRenderAssembly column . 
</p>
        <p>
Now we can use the parameter in our macro’s
</p>
        <p>
          <img title="parameters" style="border-top-width: 0px; display: inline; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="474" alt="parameters" src="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/Createacustommacroparametertype_1212C/parameters_5296818b-a8b7-42b3-9a5a-eb9b46a229da.jpg" width="953" border="0" />
        </p>
        <p>
and off course we can now use the new parameter in our template when we select the
macro
</p>
        <p>
          <img title="InsertMacro" style="border-top-width: 0px; display: inline; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="557" alt="InsertMacro" src="http://www.richardsoeteman.net/content/binary/WindowsLiveWriter/Createacustommacroparametertype_1212C/InsertMacro_2202d017-5aa8-4afc-a633-6f67b2390cb6.jpg" width="472" border="0" />
        </p>
        <p>
Another example how flexible Umbraco is. If a requirement isn’t available out of the
box, usuallyall it takes is to implement an interface and write a few lines of code.
</p>
        <img width="0" height="0" src="http://www.richardsoeteman.net/aggbug.ashx?id=24e1d561-1f6c-4411-bd62-584023d31df7" />
      </div>
    </content>
  </entry>
</feed>