<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Peter Gerritsen&#039;s blog &#187; CodePlex</title>
	<atom:link href="http://blog.petergerritsen.nl/tag/codeplex/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.petergerritsen.nl</link>
	<description>about .Net and SharePoint development</description>
	<lastBuildDate>Wed, 28 Jul 2010 08:28:17 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
		<item>
		<title>New sample project for SP2010 Word Automation: UI</title>
		<link>http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=rss</link>
		<comments>http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/#comments</comments>
		<pubDate>Tue, 02 Mar 2010 16:17:52 +0000</pubDate>
		<dc:creator>Peter Gerritsen</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[#SP2010NL]]></category>
		<category><![CDATA[CodePlex]]></category>
		<category><![CDATA[SP2010]]></category>
		<category><![CDATA[Word Automation]]></category>

		<guid isPermaLink="false">http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/</guid>
		<description><![CDATA[I’ve just published a second sample solution for the SP2010 Word Automation project on CodePlex. This solution will add a button to the Ribbon when browsing document libraries: When the button is clicked a modal Dialog is shown that will allow the user to specify the options used for conversion: When the Ok button is [...]<p><a href="http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/">New sample project for SP2010 Word Automation: UI</a> is a post from: <a href="http://blog.petergerritsen.nl">Peter Gerritsen&#039;s blog</a></p>
]]></description>
			<content:encoded><![CDATA[<p>I’ve just published a <a  href="http://sp2010wordautomation.codeplex.com/releases/view/41267" target="_blank">second sample solution</a> for the SP2010 Word Automation project on CodePlex. This solution will add a button to the Ribbon when browsing document libraries:</p>
<p><a  href="http://blog.petergerritsen.nl/wp-content/uploads/image9.png" class="thickbox no_icon" rel="gallery-782" title="Ribbon button"><img style="display: inline; border: 0px;" title="Ribbon button" src="http://blog.petergerritsen.nl/wp-content/uploads/image_thumb10.png" border="0" alt="Ribbon button" width="520" height="203" /></a></p>
<p>When the button is clicked a modal Dialog is shown that will allow the user to specify the options used for conversion:</p>
<p><a  href="http://blog.petergerritsen.nl/wp-content/uploads/image10.png" class="thickbox no_icon" rel="gallery-782" title="Modal Dialog"><img style="display: inline; border: 0px;" title="Modal Dialog" src="http://blog.petergerritsen.nl/wp-content/uploads/image_thumb11.png" border="0" alt="Modal Dialog" width="520" height="241" /></a></p>
<p>When the Ok button is clicked the selected files will be added to a conversion job and the job will be started.</p>
<p>The dialog is launched by some javascript that is specified in the CommandUIHandler section of the ribbon button definition.</p>
<pre class="brush: xml">
&lt;commandUIHandler
Command=&quot;SP2010WA_Convert_Button&quot;
CommandAction=&quot;javascript:function convertDocument() {
Sys.loadScripts([&#039;/_layouts/SP2010WordAutomation.UI/SP2010WordAutomation.UI.js&#039;], function() {
SP2010WordAutomation.UI.ConvertDocument();
});
}
convertDocument();&quot;
EnabledScript=&quot;javascript:function oneOrMoreEnable() {
var items = SP.ListOperation.Selection.getSelectedItems();
var ci = CountDictionary(items);
return (ci &gt; 0);
}
oneOrMoreEnable();&quot; /&gt;
</pre>
<p>I’ve decided to use the beta version of the ASP.Net 4.0 AJAX client library to load the required scriptfile when it is actually needed. While this is not completely necessary in this case, because the amount of script in there is quite little, it could provide a speedboost because the browser won’t load and interpret the script when the page loads.</p>
<p>The definition also contains some script to enable the button only when one or more files are selected.</p>
<p>The following lists the script that is loaded and called when the button is clicked:</p>
<pre class="brush: javascript">
Type.registerNamespace(&quot;SP2010WordAutomation.UI&quot;);

SP2010WordAutomation.UI.ConvertDocument = function () {
var items = SP.ListOperation.Selection.getSelectedItems();
var selectedItems = &#039;&#039;;
var k;

for (k in items) {
selectedItems += &#039;|&#039; + items[k].id;
}

var options = {
url: &#039;/_layouts/SP2010WordAutomation.UI/ConvertDocument.aspx?items=&#039; + selectedItems + &#039;&amp;source=&#039; + SP.ListOperation.Selection.getSelectedList(),
title: &#039;Convert Documents&#039;,
allowMaximize: false,
showClose: true,
width: 600,
height: 480,
dialogReturnValueCallback: SP2010WordAutomation.UI.ConvertCallback
};

SP.UI.ModalDialog.showModalDialog(options);
}

SP2010WordAutomation.UI.ConvertCallback = function(result, target) {
SP.UI.Notify.addNotification(target, false);

SP.UI.ModalDialog.RefreshPage(result);
}
</pre>
<p>First I use the <em>Type.registerNamespace</em> method that is provided by the standard SharePoint scriptlibrary to make sure I don’t override other methods with the same names.</p>
<p>In the <em>ConvertDocument</em> function we then launch a SharePoint dialog that will load an ApplicationPage which provides the user with the options they can choose. The <em>ConvertCallback</em> function which is called when the dialog passes a result will add a notification message to the main screen.</p>
<p>To see how this mechanism can be used, please refer to <a  href="http://blogs.msdn.com/vesku/archive/2010/02/25/how-to-sharepoint-2010-js-client-object-model-and-ui-advancements.aspx" target="_blank">this post</a> by Vesa Juvonen</p>
<!-- RO Social Bookmarks BEGIN --><div class="social_bookmark"><em>Bookmark to:</em><br /><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home?status=http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/" title="Add 'New sample project for SP2010 Word Automation: UI' to Twitter"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/twitter.png" title="Add 'New sample project for SP2010 Word Automation: UI' to Twitter" alt="Add 'New sample project for SP2010 Word Automation: UI' to Twitter" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.myspace.com/Modules/PostTo/Pages/?t=New+sample+project+for+SP2010+Word+Automation%3A+UI&#038;c=http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/" title="Add 'New sample project for SP2010 Word Automation: UI' to MySpace"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/myspace.png" title="Add 'New sample project for SP2010 Word Automation: UI' to MySpace" alt="Add 'New sample project for SP2010 Word Automation: UI' to MySpace" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/&#038;title=New+sample+project+for+SP2010+Word+Automation%3A+UI" title="Add 'New sample project for SP2010 Word Automation: UI' to Del.icio.us"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/delicious.png" title="Add 'New sample project for SP2010 Word Automation: UI' to Del.icio.us" alt="Add 'New sample project for SP2010 Word Automation: UI' to Del.icio.us" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&#038;url=http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/&#038;title=New+sample+project+for+SP2010+Word+Automation%3A+UI" title="Add 'New sample project for SP2010 Word Automation: UI' to digg"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/digg.png" title="Add 'New sample project for SP2010 Word Automation: UI' to digg" alt="Add 'New sample project for SP2010 Word Automation: UI' to digg" /></a><br /><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/share.php?u=http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/&#038;t=New+sample+project+for+SP2010+Word+Automation%3A+UI" title="Add 'New sample project for SP2010 Word Automation: UI' to FaceBook"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/facebook.png" title="Add 'New sample project for SP2010 Word Automation: UI' to FaceBook" alt="Add 'New sample project for SP2010 Word Automation: UI' to FaceBook" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/" title="Add 'New sample project for SP2010 Word Automation: UI' to Technorati"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/technorati.png" title="Add 'New sample project for SP2010 Word Automation: UI' to Technorati" alt="Add 'New sample project for SP2010 Word Automation: UI' to Technorati" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/&#038;title=New+sample+project+for+SP2010+Word+Automation%3A+UI" title="Add 'New sample project for SP2010 Word Automation: UI' to Stumble Upon"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/stumbleupon.png" title="Add 'New sample project for SP2010 Word Automation: UI' to Stumble Upon" alt="Add 'New sample project for SP2010 Word Automation: UI' to Stumble Upon" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&#038;output=popup&#038;bkmk=http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/&#038;title=New+sample+project+for+SP2010+Word+Automation%3A+UI" title="Add 'New sample project for SP2010 Word Automation: UI' to Google Bookmarks"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/google.png" title="Add 'New sample project for SP2010 Word Automation: UI' to Google Bookmarks" alt="Add 'New sample project for SP2010 Word Automation: UI' to Google Bookmarks" /></a></div>
<!-- RO Social Bookmarks END --><p><a  href="http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/">New sample project for SP2010 Word Automation: UI</a> is a post from: <a  href="http://blog.petergerritsen.nl">Peter Gerritsen&#039;s blog</a></p>
<div class="fblike" style="height:25px; height:25px; overflow:hidden;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fblog.petergerritsen.nl%2F2010%2F03%2F02%2Fnew-sample-project-for-sp2010wordautomation-ui%2F&amp;layout=standard&amp;show_faces=false&amp;width=320&amp;action=like&amp;font=arial&amp;colorscheme=light" scrolling="no" frameborder="0" allow Transparency="true" style="border:none; overflow:hidden; width:320px;"></iframe></div>]]></content:encoded>
			<wfw:commentRss>http://blog.petergerritsen.nl/2010/03/02/new-sample-project-for-sp2010wordautomation-ui/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>2 new worflow activities added to SP2010 Word Automation</title>
		<link>http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=rss</link>
		<comments>http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/#comments</comments>
		<pubDate>Thu, 18 Feb 2010 19:56:16 +0000</pubDate>
		<dc:creator>Peter Gerritsen</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[#SP2010NL]]></category>
		<category><![CDATA[CodePlex]]></category>
		<category><![CDATA[SP2010]]></category>
		<category><![CDATA[Word Automation]]></category>

		<guid isPermaLink="false">http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/</guid>
		<description><![CDATA[I’ve added two new worfklow activities, Convert Folder and Convert Library, to the SP2010 Word Automation project on CodePlex. Because you can’t associate workflows created with SharePoint designer to libraries or folders, these actions won’t use the current item from the context, so you need to specify the input and output library or folder by [...]<p><a href="http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/">2 new worflow activities added to SP2010 Word Automation</a> is a post from: <a href="http://blog.petergerritsen.nl">Peter Gerritsen&#039;s blog</a></p>
]]></description>
			<content:encoded><![CDATA[<p>I’ve added two new worfklow activities, Convert Folder and Convert Library, to the <a  href="http://sp2010wordautomation.codeplex.com" target="_blank">SP2010 Word Automation project on CodePlex</a>.</p>
<p>Because you can’t associate workflows created with SharePoint designer to libraries or folders, these actions won’t use the current item from the context, so you need to specify the input and output library or folder by url. To use the activities you can run the workflow on a other item or document. The activities locate the libraries or folders relative to the current web, so you don’t have to specify a full url:</p>
<p><a  href="http://blog.petergerritsen.nl/wp-content/uploads/image7.png" class="thickbox no_icon" rel="gallery-746" title="Convert Library Activity"><img style="display: inline; border: 0px;" title="Convert Library Activity" src="http://blog.petergerritsen.nl/wp-content/uploads/image_thumb7.png" border="0" alt="Convert Library Activity" width="540" /></a></p>
<p><a  href="http://blog.petergerritsen.nl/wp-content/uploads/image8.png" class="thickbox no_icon" rel="gallery-746" title="Convert Folder Activity"><img style="display: inline; border: 0px;" title="Convert Folder Activity" src="http://blog.petergerritsen.nl/wp-content/uploads/image_thumb8.png" border="0" alt="Convert Folder Activity" width="540" /></a></p>
<p>You can download the latest release and source code from the <a  href="http://sp2010wordautomation.codeplex.com" target="_blank">CodePlex project site</a></p>
<!-- RO Social Bookmarks BEGIN --><div class="social_bookmark"><em>Bookmark to:</em><br /><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home?status=http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/" title="Add '2 new worflow activities added to SP2010 Word Automation' to Twitter"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/twitter.png" title="Add '2 new worflow activities added to SP2010 Word Automation' to Twitter" alt="Add '2 new worflow activities added to SP2010 Word Automation' to Twitter" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.myspace.com/Modules/PostTo/Pages/?t=2+new+worflow+activities+added+to+SP2010+Word+Automation&#038;c=http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/" title="Add '2 new worflow activities added to SP2010 Word Automation' to MySpace"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/myspace.png" title="Add '2 new worflow activities added to SP2010 Word Automation' to MySpace" alt="Add '2 new worflow activities added to SP2010 Word Automation' to MySpace" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/&#038;title=2+new+worflow+activities+added+to+SP2010+Word+Automation" title="Add '2 new worflow activities added to SP2010 Word Automation' to Del.icio.us"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/delicious.png" title="Add '2 new worflow activities added to SP2010 Word Automation' to Del.icio.us" alt="Add '2 new worflow activities added to SP2010 Word Automation' to Del.icio.us" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&#038;url=http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/&#038;title=2+new+worflow+activities+added+to+SP2010+Word+Automation" title="Add '2 new worflow activities added to SP2010 Word Automation' to digg"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/digg.png" title="Add '2 new worflow activities added to SP2010 Word Automation' to digg" alt="Add '2 new worflow activities added to SP2010 Word Automation' to digg" /></a><br /><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/share.php?u=http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/&#038;t=2+new+worflow+activities+added+to+SP2010+Word+Automation" title="Add '2 new worflow activities added to SP2010 Word Automation' to FaceBook"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/facebook.png" title="Add '2 new worflow activities added to SP2010 Word Automation' to FaceBook" alt="Add '2 new worflow activities added to SP2010 Word Automation' to FaceBook" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/" title="Add '2 new worflow activities added to SP2010 Word Automation' to Technorati"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/technorati.png" title="Add '2 new worflow activities added to SP2010 Word Automation' to Technorati" alt="Add '2 new worflow activities added to SP2010 Word Automation' to Technorati" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/&#038;title=2+new+worflow+activities+added+to+SP2010+Word+Automation" title="Add '2 new worflow activities added to SP2010 Word Automation' to Stumble Upon"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/stumbleupon.png" title="Add '2 new worflow activities added to SP2010 Word Automation' to Stumble Upon" alt="Add '2 new worflow activities added to SP2010 Word Automation' to Stumble Upon" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&#038;output=popup&#038;bkmk=http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/&#038;title=2+new+worflow+activities+added+to+SP2010+Word+Automation" title="Add '2 new worflow activities added to SP2010 Word Automation' to Google Bookmarks"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/google.png" title="Add '2 new worflow activities added to SP2010 Word Automation' to Google Bookmarks" alt="Add '2 new worflow activities added to SP2010 Word Automation' to Google Bookmarks" /></a></div>
<!-- RO Social Bookmarks END --><p><a  href="http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/">2 new worflow activities added to SP2010 Word Automation</a> is a post from: <a  href="http://blog.petergerritsen.nl">Peter Gerritsen&#039;s blog</a></p>
<div class="fblike" style="height:25px; height:25px; overflow:hidden;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fblog.petergerritsen.nl%2F2010%2F02%2F18%2F2-new-worflow-activities-added-to-sp2010-word-automation%2F&amp;layout=standard&amp;show_faces=false&amp;width=320&amp;action=like&amp;font=arial&amp;colorscheme=light" scrolling="no" frameborder="0" allow Transparency="true" style="border:none; overflow:hidden; width:320px;"></iframe></div>]]></content:encoded>
			<wfw:commentRss>http://blog.petergerritsen.nl/2010/02/18/2-new-worflow-activities-added-to-sp2010-word-automation/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>CodePlex project for Word Automation Services</title>
		<link>http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=rss</link>
		<comments>http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/#comments</comments>
		<pubDate>Wed, 13 Jan 2010 14:27:45 +0000</pubDate>
		<dc:creator>Peter Gerritsen</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[#SP2010NL]]></category>
		<category><![CDATA[CodePlex]]></category>
		<category><![CDATA[SP2010]]></category>
		<category><![CDATA[Word Automation]]></category>

		<guid isPermaLink="false">http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/</guid>
		<description><![CDATA[I’ve just published the first release for a CodePlex project I started to provide sample projects / solutions for using the Word Automation Services in SharePoint 2010. Word Automation Services allow you to convert document to and from different formats. File formats the service can read: Office Open XML (DOCX, DOCM, DOTX, DOTM) Word 97-2003 [...]<p><a href="http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/">CodePlex project for Word Automation Services</a> is a post from: <a href="http://blog.petergerritsen.nl">Peter Gerritsen&#039;s blog</a></p>
]]></description>
			<content:encoded><![CDATA[<p>
I’ve just published the first release for a <a  href="http://sp2010wordautomation.codeplex.com" target="_blank">CodePlex project</a>  I started to provide sample projects / solutions for using the Word Automation Services in SharePoint 2010.
</p>
<p>
Word Automation Services allow you to convert document to and from different formats.
</p>
<p>
<em>File formats the service can read:</em>
</p>
<ul>
<li>
<em>Office Open XML (DOCX, DOCM, DOTX, DOTM) </em>
</li>
<li>
<em>Word 97-2003 Document (DOC) and Word 97-2003 Template (DOT)</em>
</li>
<li>
<em>Rich Text Format (RTF) </em>
</li>
<li>
<em>Single File Web Page (MHTML) </em>
</li>
<li>
<em>HTML </em>
</li>
<li>
<em>Word 2003 XML </em>
</li>
<li>
<em>Word 2007/2010 XML</em>
</li>
</ul>
<p>
<em>File formats the service can write:</em>
</p>
<ul>
<li>
<em>PDF </em>
</li>
<li>
<em>XPS </em>
</li>
<li>
<em>Office Open XML (DOCX, DOCM) </em>
</li>
<li>
<em>Word 97-2003 Document (DOC) </em>
</li>
<li>
<em>Rich Text Format (RTF) </em>
</li>
<li>
<em>Single File Web Page (MHTML) </em>
</li>
<li>
<em>Word 2007/2010 XML</em>
</li>
</ul>
<p>
(<a  href="http://blogs.msdn.com/microsoft_office_word/archive/2009/12/16/Word-Automation-Services_3A00_-What-It-Does.aspx">source</a>)
</p>
<p>
As far as I’ve found out, there are no UI features available out-of-the-box to use these services, so I’ve decided to create some. The first one is a custom workflow action you can use in SharePoint Designer to convert a document to many of the supported<br />
formats.
</p>
<p>
In the workflow designer you can add the “Convert Document” action:
</p>
<p>
<a  href="http://blog.petergerritsen.nl/wp-content/uploads/snipping.png" class="thickbox no_icon" rel="gallery-532" title="Workflow Actions"><img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="Workflow Actions" border="0" alt="Workflow Actions" src="http://blog.petergerritsen.nl/wp-content/uploads/snipping1.png" /></a>
</p>
<p>
The action is inserted into the workflow step where you can specify the url of the output file, select the output format and save options and select a variable for storing the conversion job id (which you can use later to retrieve the status, as the job runs asynchronous):
</p>
<p>
<a  href="http://blog.petergerritsen.nl/wp-content/uploads/snipping2.png" class="thickbox no_icon" rel="gallery-532" title="Convert document action"><img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="Convert document action" border="0" alt="Convert document action" src="http://blog.petergerritsen.nl/wp-content/uploads/snipping3.png" /></a>
</p>
<p>
<a  href="http://blog.petergerritsen.nl/wp-content/uploads/snipping4.png" class="thickbox no_icon" rel="gallery-532" title="Save Behaviour"><img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="Save Behaviour" border="0" alt="Save Behaviour" src="http://blog.petergerritsen.nl/wp-content/uploads/snipping5.png" /></a>
</p>
<p>
The job id is also logged into the Workflo w History Log (the second entry is from a second workflow action that logs the returned conversion job id variable):
</p>
<p>
<a  href="http://blog.petergerritsen.nl/wp-content/uploads/snipping6.png" class="thickbox no_icon" rel="gallery-532" title="image"><img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" src="http://blog.petergerritsen.nl/wp-content/uploads/snipping7.png" /></a>
</p>
<p>
After the job has run, which can take up to a few minutes (depending on the word automation services settings), the converted  document appears in the library:
</p>
</p>
<p>
<a  href="http://blog.petergerritsen.nl/wp-content/uploads/snipping8.png" class="thickbox no_icon" rel="gallery-532" title="image"><img style="border-right-width: 0px; display: inline; border-top-width: 0px; border-bottom-width: 0px; border-left-width: 0px" title="image" border="0" alt="image" src="http://blog.petergerritsen.nl/wp-content/uploads/snipping9.png" /></a>
</p>
<p>
The custom workflow action is one of the first features for Word Automation in SharePoint 2010 I’ve planned to release. Other  features will be a Ribbon and Item context menu extension and more Workflow actions.
</p>
<p>
Let me know if you have any suggestions for improvement or other functionality you would like to see.</p>
<!-- RO Social Bookmarks BEGIN --><div class="social_bookmark"><em>Bookmark to:</em><br /><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://twitter.com/home?status=http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/" title="Add 'CodePlex project for Word Automation Services' to Twitter"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/twitter.png" title="Add 'CodePlex project for Word Automation Services' to Twitter" alt="Add 'CodePlex project for Word Automation Services' to Twitter" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.myspace.com/Modules/PostTo/Pages/?t=CodePlex+project+for+Word+Automation+Services&#038;c=http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/" title="Add 'CodePlex project for Word Automation Services' to MySpace"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/myspace.png" title="Add 'CodePlex project for Word Automation Services' to MySpace" alt="Add 'CodePlex project for Word Automation Services' to MySpace" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://del.icio.us/post?url=http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/&#038;title=CodePlex+project+for+Word+Automation+Services" title="Add 'CodePlex project for Word Automation Services' to Del.icio.us"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/delicious.png" title="Add 'CodePlex project for Word Automation Services' to Del.icio.us" alt="Add 'CodePlex project for Word Automation Services' to Del.icio.us" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://digg.com/submit?phase=2&#038;url=http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/&#038;title=CodePlex+project+for+Word+Automation+Services" title="Add 'CodePlex project for Word Automation Services' to digg"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/digg.png" title="Add 'CodePlex project for Word Automation Services' to digg" alt="Add 'CodePlex project for Word Automation Services' to digg" /></a><br /><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.facebook.com/share.php?u=http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/&#038;t=CodePlex+project+for+Word+Automation+Services" title="Add 'CodePlex project for Word Automation Services' to FaceBook"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/facebook.png" title="Add 'CodePlex project for Word Automation Services' to FaceBook" alt="Add 'CodePlex project for Word Automation Services' to FaceBook" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.technorati.com/faves?add=http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/" title="Add 'CodePlex project for Word Automation Services' to Technorati"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/technorati.png" title="Add 'CodePlex project for Word Automation Services' to Technorati" alt="Add 'CodePlex project for Word Automation Services' to Technorati" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.stumbleupon.com/submit?url=http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/&#038;title=CodePlex+project+for+Word+Automation+Services" title="Add 'CodePlex project for Word Automation Services' to Stumble Upon"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/stumbleupon.png" title="Add 'CodePlex project for Word Automation Services' to Stumble Upon" alt="Add 'CodePlex project for Word Automation Services' to Stumble Upon" /></a><a  class="social_img" onclick="window.open(this.href, '_blank', 'scrollbars=yes,menubar=no,border=0,height=600,width=750,resizable=yes,toolbar=no,location=no,status=no'); return false;" href="http://www.google.com/bookmarks/mark?op=edit&#038;output=popup&#038;bkmk=http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/&#038;title=CodePlex+project+for+Word+Automation+Services" title="Add 'CodePlex project for Word Automation Services' to Google Bookmarks"><img src="http://blog.petergerritsen.nl/wp-content/plugins/ro-social-bookmarks/google.png" title="Add 'CodePlex project for Word Automation Services' to Google Bookmarks" alt="Add 'CodePlex project for Word Automation Services' to Google Bookmarks" /></a></div>
<!-- RO Social Bookmarks END --><p><a  href="http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/">CodePlex project for Word Automation Services</a> is a post from: <a  href="http://blog.petergerritsen.nl">Peter Gerritsen&#039;s blog</a></p>
<div class="fblike" style="height:25px; height:25px; overflow:hidden;"><iframe src="http://www.facebook.com/plugins/like.php?href=http%3A%2F%2Fblog.petergerritsen.nl%2F2010%2F01%2F13%2Fcodeplex-project-for-word-automation-services%2F&amp;layout=standard&amp;show_faces=false&amp;width=320&amp;action=like&amp;font=arial&amp;colorscheme=light" scrolling="no" frameborder="0" allow Transparency="true" style="border:none; overflow:hidden; width:320px;"></iframe></div>]]></content:encoded>
			<wfw:commentRss>http://blog.petergerritsen.nl/2010/01/13/codeplex-project-for-word-automation-services/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
