<?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>Ideas For Free &#187; SharePoint Designer</title>
	<atom:link href="http://blog.libinuko.com/tag/sharepoint-designer/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.libinuko.com</link>
	<description>Only freedom will grow our ideas</description>
	<lastBuildDate>Sun, 18 Dec 2011 04:51:16 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>SharePoint Designer: Visual Touch Using Using Conditional Formatting</title>
		<link>http://blog.libinuko.com/2011/05/04/sharepoint-designer-visual-touch-using-using-conditional-formatting/</link>
		<comments>http://blog.libinuko.com/2011/05/04/sharepoint-designer-visual-touch-using-using-conditional-formatting/#comments</comments>
		<pubDate>Wed, 04 May 2011 15:26:27 +0000</pubDate>
		<dc:creator>cakriwut</dc:creator>
				<category><![CDATA[Office]]></category>
		<category><![CDATA[Office 2010]]></category>
		<category><![CDATA[SharePoint 2010]]></category>
		<category><![CDATA[SharePoint Designer 2010]]></category>
		<category><![CDATA[Howto]]></category>
		<category><![CDATA[SharePoint Designer]]></category>

		<guid isPermaLink="false">http://blog.libinuko.com/?p=641</guid>
		<description><![CDATA[English: Conditional formatting now becomes easier using SharePoint Designer 2010. We can create intelligent view which able to highlight some important pointer in the display. There are 3 types of conditional formatting: 1. Show content , show content based on the pre-specified conditions 2. Hide content , hide content based on the pre-specified [...] <a href="http://blog.libinuko.com/2011/05/04/sharepoint-designer-visual-touch-using-using-conditional-formatting/">[read more...]</a>]]></description>
			<content:encoded><![CDATA[<!-- google_ad_section_start --><p>English:</p>
<p>Conditional formatting now becomes easier using SharePoint Designer 2010. We can create <strong>intelligent view which able to highlight some important pointer</strong> in the display. There are 3 types of conditional formatting:</p>
<p>1. <strong>Show content</strong> , show content based on the pre-specified conditions     <br />2. <strong>Hide content</strong> , hide content based on the pre-specified conditions     <br />3. <strong>Apply formatting</strong> , apply formatting based on the pre-specified conditions.</p>
<p>&#160;</p>
<p><strong>Visual Touch for Easy Reading</strong></p>
<p>Imagine, that you have developed a workflow that uses task list to assign task to the users. The standard task list, may look like this:</p>
<p><a href="http://blog.libinuko.com/files/2011/05/NormalTask.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="NormalTask" border="0" alt="NormalTask" src="http://blog.libinuko.com/files/2011/05/NormalTask_thumb.jpg" width="881" height="505" /></a></p>
<p>Actually there is nothing wrong with the task list web-part. However, since there <strong>isn’t any pointer on important information </strong>in the task list – then <strong>the message may not be conveyed efficiently</strong> to the reader. </p>
<p>Using conditional formatting, we will be able highlight overdue tasks, so that the task will get more attention from the user. In the picture below, we add <strong>red hand</strong> icon, if the <strong>task is overdue</strong>.</p>
<p><a href="http://blog.libinuko.com/files/2011/05/ConditionalFormattingTask.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="ConditionalFormattingTask" border="0" alt="ConditionalFormattingTask" src="http://blog.libinuko.com/files/2011/05/ConditionalFormattingTask_thumb.jpg" width="751" height="509" /></a></p>
<p>&#160;</p>
<p><strong>So, how would we do that?</strong></p>
<p>Following step-by-step will show how to create conditional formatting using SharePoint Designer 2010. I will demonstrate how to add red-hand icon to the overdue task.</p>
<p>&#160;</p>
<p>1. Open original task list view in SharePoint Designer 2010.</p>
<p><a href="http://blog.libinuko.com/files/2011/05/TaskListView.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="TaskListView" border="0" alt="TaskListView" src="http://blog.libinuko.com/files/2011/05/TaskListView_thumb.jpg" width="835" height="472" /></a></p>
<p>&#160;</p>
<p>2. Select Title column tag and then create conditional formatting by selecting <strong>Apply formatting…</strong>.</p>
<p><a href="http://blog.libinuko.com/files/2011/05/TaskListView2.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="TaskListView2" border="0" alt="TaskListView2" src="http://blog.libinuko.com/files/2011/05/TaskListView2_thumb.jpg" width="837" height="456" /></a></p>
<p>&#160;</p>
<p>3. Define formatting condition as follows:</p>
<blockquote><p>Due Date&#160; &lt;&#160; [Current Date]&#160;&#160;&#160;&#160; And</p>
<p>Status&#160;&#160;&#160;&#160;&#160; &lt;&gt;&#160; ‘Completed’</p>
</blockquote>
<p>&#160;</p>
<p><a href="http://blog.libinuko.com/files/2011/05/TaskListView3.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="TaskListView3" border="0" alt="TaskListView3" src="http://blog.libinuko.com/files/2011/05/TaskListView3_thumb.jpg" width="745" height="480" /></a></p>
<p>and then click <strong>Set Style</strong>.</p>
<p>&#160;</p>
<p>4. I have uploaded the icon in Site Assets gallery, so that I can use it as background-image.</p>
<p><a href="http://blog.libinuko.com/files/2011/05/TaskListView4.jpg"><img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="TaskListView4" border="0" alt="TaskListView4" src="http://blog.libinuko.com/files/2011/05/TaskListView4_thumb.jpg" width="846" height="544" /></a></p>
<p>And finally I have configure my style to:</p>
<blockquote><p>background-image: url(&#8216;../../SiteAssets/Pointer_red_22x17.gif&#8217;); background-repeat: no-repeat; background-position: left bottom; text-indent: 20px</p>
</blockquote>
<p>5. Save the changes, and you’ve done with the conditional formatting.</p>
<p>&#160;</p>
<p>Finally, adding visual touch using conditional formatting is also adding more value to the user. It will make the information more knowledgeable than plain presentation.</p>
<!-- google_ad_section_end -->]]></content:encoded>
			<wfw:commentRss>http://blog.libinuko.com/2011/05/04/sharepoint-designer-visual-touch-using-using-conditional-formatting/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>SharePoint 2010: How to create Cascading Lookup Field using Client Object Model</title>
		<link>http://blog.libinuko.com/2011/01/29/sharepoint-2010-how-to-create-cascading-lookup-field-using-client-object-model/</link>
		<comments>http://blog.libinuko.com/2011/01/29/sharepoint-2010-how-to-create-cascading-lookup-field-using-client-object-model/#comments</comments>
		<pubDate>Sat, 29 Jan 2011 15:49:50 +0000</pubDate>
		<dc:creator>cakriwut</dc:creator>
				<category><![CDATA[SharePoint 2010]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[Client Object Model]]></category>
		<category><![CDATA[SharePoint Designer]]></category>

		<guid isPermaLink="false">http://blog.libinuko.com/2011/01/29/sharepoint-2010-how-to-create-cascading-lookup-field-using-client-object-model/</guid>
		<description><![CDATA[English In previous post I have demonstrated “How to create cascading lookup field” in SharePoint 2010 using InfoPath. I will extend the possibility by utilizing Client Object Model and SharePoint Designer; therefore we don’t need InfoPath to have the cascading lookup field. Using same scenario where City is cascading lookup field from the selected Country, we’ll see [...] <a href="http://blog.libinuko.com/2011/01/29/sharepoint-2010-how-to-create-cascading-lookup-field-using-client-object-model/">[read more...]</a>]]></description>
			<content:encoded><![CDATA[<!-- google_ad_section_start --><p>English</p>
<p>In previous post I have demonstrated “<a href="http://blog.libinuko.com/2010/07/21/sharepoint-2010-how-to-create-cascading-lookup-field/" target="_blank">How to create cascading lookup field</a>” in SharePoint 2010 using InfoPath. I will extend the possibility by utilizing Client Object Model and SharePoint Designer; therefore we don’t need InfoPath to have the cascading lookup field.</p>
<p>Using same scenario where City is cascading lookup field from the selected Country, we’ll see together how Client Object Model solve the problem. In this solution we need to create JS referral to SP.js for Client Object Model and JQuery to help us working with DOM.</p>
<br /><img src="http://i.ytimg.com/vi/sFiPtoGpjFI/0.jpg" alt="media" /><br />
[See post to watch Flash video]
<p>Some key points in the video:</p>
<p>1. Put JQuery distribution in 14hive\Layouts.</p>
<p>2. Add Javascript link referral in the AdditionalPageHead place holder.</p>
<div id="codeSnippetWrapper" style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; width: 97.5%; font-family: 'Courier New', courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; cursor: text; border: silver 1px solid; padding: 4px;">
<div id="codeSnippet" style="text-align: left; line-height: 12pt; background-color: #f4f4f4; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;">
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum1" style="color: #606060;">   1:</span> <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">SharePoint:ScriptLink</span> <span style="color: #ff0000;">Language</span><span style="color: #0000ff;">="Javascript"</span> <span style="color: #ff0000;">Localizable</span><span style="color: #0000ff;">="False"</span> <span style="color: #ff0000;">runat</span><span style="color: #0000ff;">="server"</span> <span style="color: #ff0000;">Name</span><span style="color: #0000ff;">="jquery-1.4.4.min.js"</span><span style="color: #0000ff;">/&gt;</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum2" style="color: #606060;">   2:</span> <span style="color: #0000ff;">&lt;</span><span style="color: #800000;">SharePoint:ScriptLink</span> <span style="color: #ff0000;">Name</span><span style="color: #0000ff;">="SP.js"</span> <span style="color: #ff0000;">runat</span><span style="color: #0000ff;">="server"</span> <span style="color: #ff0000;">OnDemand</span><span style="color: #0000ff;">="true"</span> <span style="color: #ff0000;">Localizable</span><span style="color: #0000ff;">="false"</span><span style="color: #0000ff;">/&gt;</span></pre>
<p><!--CRLF--></p>
</div>
</div>
<p>3. Add Javascript code to modify cascading selector and create Client Object Model call to retrieve cascaded value in Main conten place holder.</p>
<div id="codeSnippetWrapper" style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 20px 0px 10px; width: 97.5%; font-family: 'Courier New', courier, monospace; direction: ltr; max-height: 200px; font-size: 8pt; overflow: auto; cursor: text; border: silver 1px solid; padding: 4px;">
<div id="codeSnippet" style="text-align: left; line-height: 12pt; background-color: #f4f4f4; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;">
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum1" style="color: #606060;">   1:</span> &lt;script type=<span style="color: #006080;">"text/javascript"</span>&gt;</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum2" style="color: #606060;">   2:</span> <span style="color: #008000;">// JQuery_Script</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum3" style="color: #606060;">   3:</span> </pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum4" style="color: #606060;">   4:</span> <span style="color: #0000ff;">var</span> spListItems;</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum5" style="color: #606060;">   5:</span> </pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100.07%; font-family: 'Courier New', courier, monospace; direction: ltr; height: 20px; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum6" style="color: #606060;">   6:</span> <span style="color: #008000;">// Cascading lookup main function</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum7" style="color: #606060;">   7:</span> <span style="color: #0000ff;">function</span> FilterLookup(filterSource,lookupList)</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum8" style="color: #606060;">   8:</span> {</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum9" style="color: #606060;">   9:</span>    <span style="color: #0000ff;">var</span> filterElement = $(<span style="color: #006080;">"select[title='"</span> + filterSource + <span style="color: #006080;">"'] option:selected"</span>);</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum10" style="color: #606060;">  10:</span>    <span style="color: #0000ff;">if</span>(filterElement.length == 0) <span style="color: #0000ff;">return</span>;</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum11" style="color: #606060;">  11:</span> </pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum12" style="color: #606060;">  12:</span>    <span style="color: #0000ff;">var</span> selectedFilterText =  filterElement.text();</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum13" style="color: #606060;">  13:</span>    <span style="color: #0000ff;">var</span> selectedFilterValue = filterElement.value;</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum14" style="color: #606060;">  14:</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum15" style="color: #606060;">  15:</span>    <span style="color: #0000ff;">var</span> clientCtx = <span style="color: #0000ff;">new</span> SP.ClientContext.get_current();</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum16" style="color: #606060;">  16:</span>    <span style="color: #0000ff;">var</span> spList = clientCtx.get_web().get_lists().getByTitle(lookupList);</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum17" style="color: #606060;">  17:</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum18" style="color: #606060;">  18:</span>    <span style="color: #0000ff;">var</span> camlQuery = <span style="color: #0000ff;">new</span> SP.CamlQuery();</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum19" style="color: #606060;">  19:</span>    camlQuery.set_viewXml(<span style="color: #006080;">'&lt;View&gt;&lt;Query&gt;&lt;Where&gt;&lt;Eq&gt;&lt;FieldRef Name=\''</span>+ filterSource +<span style="color: #006080;">'\'/&gt;'</span> +</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum20" style="color: #606060;">  20:</span>         <span style="color: #006080;">'&lt;Value Type=\'Text\'&gt;'</span>+ selectedFilterText +<span style="color: #006080;">'&lt;/Value&gt;&lt;/Eq&gt;&lt;/Where&gt;&lt;/Query&gt;&lt;/View&gt;'</span>);</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum21" style="color: #606060;">  21:</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum22" style="color: #606060;">  22:</span>    <span style="color: #0000ff;">this</span>.spListItems = spList.getItems(camlQuery);</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum23" style="color: #606060;">  23:</span>    clientCtx.load(spListItems);</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum24" style="color: #606060;">  24:</span>    clientCtx.executeQueryAsync(Function.createDelegate(<span style="color: #0000ff;">this</span>, <span style="color: #0000ff;">this</span>.onQuerySucceeded), Function.createDelegate(<span style="color: #0000ff;">this</span>, <span style="color: #0000ff;">this</span>.onQueryFailed) );</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum25" style="color: #606060;">  25:</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum26" style="color: #606060;">  26:</span> } <span style="color: #008000;">// </span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum27" style="color: #606060;">  27:</span> </pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum28" style="color: #606060;">  28:</span> <span style="color: #0000ff;">function</span> onQuerySucceeded(sender, args) {</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum29" style="color: #606060;">  29:</span> </pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum30" style="color: #606060;">  30:</span>    alert(<span style="color: #0000ff;">this</span>.selectedFilterText);</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum31" style="color: #606060;">  31:</span>    <span style="color: #008000;">// Get CityElement Select or Input</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum32" style="color: #606060;">  32:</span>    <span style="color: #0000ff;">var</span> cityElement = $(<span style="color: #006080;">"select[title='City']"</span>);</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum33" style="color: #606060;">  33:</span>    <span style="color: #0000ff;">if</span>(cityElement.length == 0) { alert(<span style="color: #006080;">'Unknown'</span>); }</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum34" style="color: #606060;">  34:</span> </pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum35" style="color: #606060;">  35:</span>     <span style="color: #0000ff;">var</span> options = <span style="color: #006080;">''</span>;</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum36" style="color: #606060;">  36:</span>     <span style="color: #0000ff;">var</span> listItemEnumerator = spListItems.getEnumerator();</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum37" style="color: #606060;">  37:</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum38" style="color: #606060;">  38:</span>     <span style="color: #0000ff;">while</span> (listItemEnumerator.moveNext()) {</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum39" style="color: #606060;">  39:</span>         <span style="color: #0000ff;">var</span> oListItem = listItemEnumerator.get_current();</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum40" style="color: #606060;">  40:</span>         options += <span style="color: #006080;">'&lt;option value="'</span> + oListItem.get_id() + <span style="color: #006080;">'"&gt;'</span> + oListItem.get_item(<span style="color: #006080;">'Title'</span>) +<span style="color: #006080;">'&lt;/option&gt;'</span>;</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum41" style="color: #606060;">  41:</span>     }</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum42" style="color: #606060;">  42:</span>    cityElement.html(options);</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum43" style="color: #606060;">  43:</span> }</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum44" style="color: #606060;">  44:</span> </pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum45" style="color: #606060;">  45:</span> <span style="color: #0000ff;">function</span> onQueryFailed(sender, args) {</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum46" style="color: #606060;">  46:</span>     alert(<span style="color: #006080;">'Request failed. '</span> + args.get_message() + <span style="color: #006080;">'\n'</span> + args.get_stackTrace());</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum47" style="color: #606060;">  47:</span> }</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum48" style="color: #606060;">  48:</span> </pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum49" style="color: #606060;">  49:</span> </pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum50" style="color: #606060;">  50:</span> <span style="color: #008000;">// Attach function on document ready</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum51" style="color: #606060;">  51:</span> $(document).ready(</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum52" style="color: #606060;">  52:</span>    <span style="color: #0000ff;">function</span>() {</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum53" style="color: #606060;">  53:</span>       ExecuteOrDelayUntilScriptLoaded(FilterLookup,<span style="color: #006080;">"sp.js"</span>);</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum54" style="color: #606060;">  54:</span>       <span style="color: #008000;">//FilterLookup("Country","City");</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum55" style="color: #606060;">  55:</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum56" style="color: #606060;">  56:</span>        <span style="color: #008000;">// Get CountryElement Select or Input</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum57" style="color: #606060;">  57:</span>       <span style="color: #0000ff;">var</span> countryElement = $(<span style="color: #006080;">"select[title='Country']"</span>);</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum58" style="color: #606060;">  58:</span>       <span style="color: #0000ff;">if</span>(countryElement.length == 0)</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum59" style="color: #606060;">  59:</span>       {</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum60" style="color: #606060;">  60:</span>            countryElement = $(<span style="color: #006080;">"input[title='Country']"</span>);</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum61" style="color: #606060;">  61:</span>       }</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum62" style="color: #606060;">  62:</span>       <span style="color: #0000ff;">if</span>(countryElement.length != 0) {</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum63" style="color: #606060;">  63:</span>        <span style="color: #0000ff;">if</span>(countryElement[0].optHid) {</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum64" style="color: #606060;">  64:</span>           $(<span style="color: #006080;">"input[id='"</span> + countryElement[0].optHid + <span style="color: #006080;">"']"</span>).bind(<span style="color: #006080;">"propertychange"</span>, <span style="color: #0000ff;">function</span>() { FilterCity(); });</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum65" style="color: #606060;">  65:</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum66" style="color: #606060;">  66:</span>        } <span style="color: #0000ff;">else</span>{</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum67" style="color: #606060;">  67:</span>           $(<span style="color: #006080;">"select[title='Country']"</span>).change(<span style="color: #0000ff;">function</span>() { FilterLookup(<span style="color: #006080;">"Country"</span>,<span style="color: #006080;">"City"</span>); });</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum68" style="color: #606060;">  68:</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum69" style="color: #606060;">  69:</span>        }</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum70" style="color: #606060;">  70:</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum71" style="color: #606060;">  71:</span>    }</pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum72" style="color: #606060;">  72:</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum73" style="color: #606060;">  73:</span> </pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum74" style="color: #606060;">  74:</span>    }); <span style="color: #008000;">// Document ready</span></pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: white; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum75" style="color: #606060;">  75:</span> </pre>
<p><!--CRLF--></p>
<pre style="text-align: left; line-height: 12pt; background-color: #f4f4f4; margin: 0em; width: 100%; font-family: 'Courier New', courier, monospace; direction: ltr; color: black; font-size: 8pt; overflow: visible; border-style: none; padding: 0px;"><span id="lnum76" style="color: #606060;">  76:</span> &lt;/script&gt;</pre>
<p><!--CRLF--></p>
</div>
</div>
<p>4. Finally save and set the new form as default form.</p>
<!-- google_ad_section_end -->]]></content:encoded>
			<wfw:commentRss>http://blog.libinuko.com/2011/01/29/sharepoint-2010-how-to-create-cascading-lookup-field-using-client-object-model/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>SPD: How to change 24hr format to 12hr format AM/PM</title>
		<link>http://blog.libinuko.com/2009/09/04/spd-how-to-change-24hr-format-to-12hr-format-ampm/</link>
		<comments>http://blog.libinuko.com/2009/09/04/spd-how-to-change-24hr-format-to-12hr-format-ampm/#comments</comments>
		<pubDate>Fri, 04 Sep 2009 00:03:11 +0000</pubDate>
		<dc:creator>cakriwut</dc:creator>
				<category><![CDATA[SharePoint 2007]]></category>
		<category><![CDATA[Tips and Tricks]]></category>
		<category><![CDATA[SharePoint Designer]]></category>

		<guid isPermaLink="false">http://blog.libinuko.com/2009/09/04/spd-how-to-change-24hr-format-to-12hr-format-ampm/</guid>
		<description><![CDATA[English I’ve found this question in forum – but since it was not easy to explain by sentences, I would like to create a sample working option here. For example you have this list as data source: In the data source you have 24hr format (I use string type for my sample, but you can use normal [...] <a href="http://blog.libinuko.com/2009/09/04/spd-how-to-change-24hr-format-to-12hr-format-ampm/">[read more...]</a>]]></description>
			<content:encoded><![CDATA[<!-- google_ad_section_start --><p>English</p>
<p>I’ve found this question in forum – but since it was not easy to explain by sentences, I would like to create a sample working option here.</p>
<p>For example you have this list as data source:</p>
<p><a href="http://blog.libinuko.com/wp-content/uploads/2009/09/94200973007AM.gif"><img style="border-bottom: 0px;border-left: 0px;border-top: 0px;border-right: 0px" border="0" alt="9-4-2009 7-30-07 AM" src="http://blog.libinuko.com/wp-content/uploads/2009/09/94200973007AM_thumb.gif" width="501" height="149" /></a> </p>
</p>
<p>In the data source you have 24hr format (I use string type for my sample, but you can use normal DateTime).</p>
<p>In SharePoint, to display the 24hr format in 12hr format, you need to use DataFormWebpart + proper ddwrt function like this:</p>
<p><a href="http://blog.libinuko.com/wp-content/uploads/2009/09/94200975828AM.gif"><img style="border-bottom: 0px;border-left: 0px;border-top: 0px;border-right: 0px" border="0" alt="9-4-2009 7-58-28 AM" src="http://blog.libinuko.com/wp-content/uploads/2009/09/94200975828AM_thumb.gif" width="430" height="307" /></a> </p>
<p>The ddwrt function you need to play is:</p>
<blockquote><p>ddwrt:FormatDate(string([Field]),1033,5)</p>
</blockquote>
<p><strong>[Field]</strong> is the field where you have the data, in this case internal name of “24hr format”.    <br /><strong>1033</strong> is the culture    <br /><strong>5</strong> is the predefined format , you can use ‘M/d/yyyy hh:mm:ss tt’ instead.</p>
<p>&#160;</p>
<p>And the final result will be,</p>
<p><a href="http://blog.libinuko.com/wp-content/uploads/2009/09/94200980218AM.gif"><img style="border-bottom: 0px;border-left: 0px;border-top: 0px;border-right: 0px" border="0" alt="9-4-2009 8-02-18 AM" src="http://blog.libinuko.com/wp-content/uploads/2009/09/94200980218AM_thumb.gif" width="369" height="149" /></a> </p>
<p>&#160;</p>
<p>Happy design!</p>
<!-- google_ad_section_end -->]]></content:encoded>
			<wfw:commentRss>http://blog.libinuko.com/2009/09/04/spd-how-to-change-24hr-format-to-12hr-format-ampm/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

