<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Sharepoint Musing's</title>
	<atom:link href="http://sharepointhelps.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://sharepointhelps.wordpress.com</link>
	<description>SharePoint Products and Technologies - Connecting People,Process and Information</description>
	<lastBuildDate>Thu, 05 Jan 2012 07:41:05 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='sharepointhelps.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Sharepoint Musing's</title>
		<link>http://sharepointhelps.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://sharepointhelps.wordpress.com/osd.xml" title="Sharepoint Musing&#039;s" />
	<atom:link rel='hub' href='http://sharepointhelps.wordpress.com/?pushpress=hub'/>
		<item>
		<title>What a Good SharePoint Consultant Should Know!</title>
		<link>http://sharepointhelps.wordpress.com/2008/08/23/what-a-good-sharepoint-consultant-should-know/</link>
		<comments>http://sharepointhelps.wordpress.com/2008/08/23/what-a-good-sharepoint-consultant-should-know/#comments</comments>
		<pubDate>Sat, 23 Aug 2008 04:21:11 +0000</pubDate>
		<dc:creator>vamsankar</dc:creator>
				<category><![CDATA[AJAX with Sharepoint]]></category>
		<category><![CDATA[Microsoft Office Sharepoint Server]]></category>
		<category><![CDATA[Windows Sharepoint Services]]></category>

		<guid isPermaLink="false">http://sharepointhelps.wordpress.com/?p=76</guid>
		<description><![CDATA[Everyone who can spell SharePoint o            What is Sharepoint?   Sharepoint is the portal. It is developed by Microsoft. This is used to create Content Management System web sites. We can develop individual sites, team sites and enterprise portals.   o            What is the difference between Sharepoint Portal Server and Windows Sharepoint Services?   Sharepoint [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=76&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 6pt;"><strong><em><span style="font-size:10pt;color:#333333;font-family:Arial;">Everyone who can spell SharePoint</span></em></strong></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 6pt;"><strong><em></em></strong><strong><span style="font-size:10pt;color:#333333;font-family:Arial;"></span></strong></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is Sharepoint? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Sharepoint is the portal. It is developed by Microsoft. This is used to create Content Management System web sites. We can develop individual sites, team sites and enterprise portals.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is the difference between Sharepoint Portal Server and Windows Sharepoint Services? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Sharepoint Portal Server features are very high. Search portal and navigations are most important features of the Sharepoint Portal Server.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Windows Sharepoint Services are used to create CMS Web sites and blogs, Forums and document sharing Libraries.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is a document library? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">To share a document that referenced in news, articles published site.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is a meeting workspace? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Meeting workspace is used to store information about particular organization employees work related tasks meetings (related information). And also place the minutes of the meeting and each person task details.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is a document workspace? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">To share a document with others, we create a document workspace site. We can easily share documents and some other files. We can give each and every file permissions.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is a web part?</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 6pt 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">WSS 3.0 has a new infrastructure called Web Part. The WSS Web part classes are derived from ASP.Net Web Part Class. It is supported by Widows Sharepoint Services 3.0. We can also create connectable web parts. The connectable web part is connected to any other related web part. These two connected web parts are has some programs.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 6pt 12pt;"> </p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 6pt;"><em><span style="font-size:10pt;color:#333333;font-family:Arial;"><strong>Mid-level SharePoint Consultant</strong></span></em></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 6pt;"><em><span style="font-size:10pt;color:#333333;font-family:Arial;"><strong></strong></span></em><span style="font-size:10pt;color:#333333;font-family:Arial;"></span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is the difference between a document library and a form library? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Document Library has documents and content, which gets stored in the Sharepoint content database.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Form Library has an Info path XML forms. </span><span style="font-size:10pt;font-family:Arial;">When submitting with InfoPath Form Services, the submitted data is generated as XML which refers the original form template .XSN. The XML files are stored in Document Library.</span><span style="font-size:10pt;color:#333333;font-family:Arial;"></span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is a web part zone? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Web Parts are displayed by using Web Part Zone. The WebPartZone class derived from WebZone and WebPartZoneBase classes. A Web Part zone is a WebPart container that can be configured to control the organization and format of the Web Parts contained in it.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 0.5in;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">How is security managed in SharePoint? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Sharepoint using three types of user authentications. There are Windows, Form and Single Sign On. </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Security Socket Layer (SSL) is also used for authentication in Sharepoint. Authorization, Authentication and Impersonation these are configured by config file. </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">How are web parts developed? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">WebParts developed by using Visual Studio .Net 2005. It offers many Sharepoint templates like Site Definition, Web Part etc. And also using Widows Class Library.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 0.5in;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is a site definition? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">A Site Definition is a group of files that used to define a unique type of Sharepoint Site. Example, </span><span style="font-size:10pt;font-family:Arial;" lang="EN">one site definition defines the Team Site, Blank Site, and Document Workspace templates, and another site definition defines the Basic Meeting Workspace, Blank Meeting Workspace, Decision Meeting Workspace, Social Meeting Workspace, and Multipage Meeting Workspace templates.</span><span style="font-size:10pt;color:#333333;font-family:Arial;"></span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is a template? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Templates are built-in solutions for applications, business portals, Design and Look &amp; Feel. Sharepoint has a some pre-build templates. The templates are customizing and deploying in to the server.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">How do you install web parts? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<ol style="margin-top:0;" type="1">
<li class="MsoNormal"><span style="font-size:10pt;font-family:Arial;">Open the Command prompt in Visual studio .Net.</span></li>
<li class="MsoNormal"><span style="font-size:10pt;font-family:Arial;">Find the path for you developed web part dll file path.</span></li>
<li class="MsoNormal"><span style="font-size:10pt;font-family:Arial;">Type the command gacutil /I<span>  </span>dll name, then press enter.</span></li>
<li class="MsoNormal"><span style="font-size:10pt;font-family:Arial;">Reset the IIS using iisreset command.</span></li>
<li class="MsoNormal"><span style="font-size:10pt;font-family:Arial;">Open the Folder “C:\Inetpub\wwwroot\” Open the web.config file. Copy the SafeControl for your installed web Part. And Open your web site config file, paste here the SafeControl tag.</span></li>
<li class="MsoNormal"><span style="font-size:10pt;font-family:Arial;">Open your web site. Go to Site Actions &gt; Site Settings &gt; Site collection Features. Now find and activate your installed web Part.</span></li>
<li class="MsoNormal"><span style="font-size:10pt;font-family:Arial;">Next, go to site settings&gt; Web Parts here click the “New” link. Here find your installed Web Part and select. Then press “Pop up Gallery” button.</span></li>
<li class="MsoNormal"><span style="font-size:10pt;font-family:Arial;">Now you can add web part any page in this site.</span></li>
</ol>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is the difference between a site and a web? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Site is defined as Website. It has many subsites.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Web is a single subsite of the Site.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What are the differences between web part page gallery, site gallery, virtual server gallery and online gallery? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">1. Web Part Gallery has a many WebParts.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">2. Site Gallery has a many site galleries. For example. Shared Document, Calendar, Announcement, Lists, Tasks, Team Discussion.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">3. Virtual Server Gallery has developer developed web parts are stored in a particular server.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"><span>  </span></span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is the GAC? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">GAC is Global Assembly Cache. Each computer where the CLR installed has a machine code is called GAC. It stores assemblies. We can use GAC to install the web parts in Sharepoint application.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is a DWP? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">DWP means Dashboard Web Part. The DWP files are importing to the Sharepoint Site after we used.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is CAML? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">CAML is </span><em><span style="font-size:10pt;font-style:normal;font-family:Arial;">Collaborative Application Markup Language. It is the XML based language. That is used to build a customize web site based on Sharepoint services. It is used to get a list values, particular data in a list. </span></em><span style="font-size:10pt;color:#333333;font-family:Arial;"></span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What are themes? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">A theme is a collection of CSS and Graphics. That are modifying / customizing how a web site looks you want.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">A Basic web site needs a graphical look and feel. Sharepoint has a some built-in themes. We can create new themes is possible for Sharepoint site.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 0.5in;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is presence? </span></p>
<p class="doclist" style="margin:auto 0 auto 0.25in;"><a name="features_include"></a><span style="font-size:10pt;font-family:Arial;">Groove features include presence information, chat, application sharing, file sharing, contacts, messaging, project management, data sharing, and content synchronization.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Can web parts be connected? If so, how? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 0.5in;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Yes. Two web parts has sharing information in a runtime. We use the Connection Interfaces to create Connectable Web parts.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is a personal view and what is a shared view? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">A Web Part page view has two views. There are Personal view and Shared View. </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Personal View: This view is set by each user. For example, one user has changed the list in some format. The changes will not see the other users.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Shared View: This view web part designs and any thing is not changed by users. Users will not be changed these types of web parts. The site admin can change the web part view and anything</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is an STP file? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">STP means Site Template. We can create new site definition. This definition has webparts and list (there are derived from default Sharepoint components). We can save the file for .stp format.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is an FWP file? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">FWP file is nothing a backup file for Sharepoint site. We can restore and backup the Sharepoint site.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Can you upload MP3&#8242;s to SharePoint? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 0.5in;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Yes. (http://manish-sharepoint.blogspot.com/2008/06/playing-audiovideo-files-within.html)</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">how does SharePoint support MS Outlook integration? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">We can use some features from OutLook in Sharepoint, ex. Calendar and contacts</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">How can you extend lists in SharePoint? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">We expand the size of the lists. </span><span style="font-size:10pt;color:#333333;font-family:Arial;">Click Start, point to All </span><span style="font-size:10pt;font-family:Arial;"><a href="void(0)"><span style="color:windowtext;text-decoration:none;">Programs</span></a><span style="color:#333333;">, point to Administrative Tools, and then click SharePoint Central Administration.</span></span><span style="font-size:10pt;color:#333333;font-family:Arial;"></span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Explain the document versioning in SharePoint document libraries</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;">We can maintain version in all Sharepoint libraries and lists.<span>  </span>When we upload or update any document, while Sharepoint creates version.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"></span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 6pt;"><strong><em><span style="font-size:10pt;color:#333333;font-family:Arial;">Senior SharePoint Consultant</span></em></strong></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 6pt;"><strong><em><span style="font-size:10pt;color:#333333;font-family:Arial;"></span></em></strong></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Where is web part resources contained? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">The WebPart resources can not part of the DLL, because there are used in url based. Like images, jscript files. The WebPart is installed in GAC and Bin directory.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What are the different installation methods for deploying web parts? And what are the pros/cons? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<ul style="margin-top:0;" type="disc">
<li class="MsoNormal"><span style="font-size:10pt;font-family:Arial;">We use GAC</span></li>
<li class="MsoNormal"><span style="font-size:10pt;font-family:Arial;">We develop web part in Windows Class Library. While the web part once runs, it will install automatically in GAC.</span></li>
</ul>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is a ghosted/unghosted page? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">A Ghosted Page is modified by Sharepoint Designer. Example, Master page.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">An Unghosted Page is not modified by Sharepoint Designer. Example, forum pages, calendar lists etc</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">It has another one page there is “Reghosted” it means by Reset to Site Definition</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">How is site data stored? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 0.5in;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 0.5in;"><span style="font-size:10pt;color:#333333;font-family:Arial;">In Database.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 0.5in;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Where is metadata for a web stored? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:0.25in;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Meta Data is stored inside XML files on the server or SQL Server database.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is an audience and describe the use? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"><a href="http://www.microsoft.com/learning/en/us/syllabi/3370bfinal.mspx#EJB"><span style="color:#777777;">http://www.microsoft.com/learning/en/us/syllabi/3370bfinal.mspx#EJB</span></a></span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;font-family:Arial;">The primary audience for this clinic is the IT Professional who generally works with both Windows and Office technologies. The types of duties that are typical of this IT Professional are administrative and support duties such as planning and deployment of Office server products in a Microsoft Windows environment, configuration and security administration, and updates of Office upgrades and patches. The target audience for this clinic is IT Professionals that want an overview of what Microsoft Office SharePoint Server 2007 is, and how to deploy it.</span><span style="font-size:10pt;color:#333333;font-family:Arial;"></span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What are the trust levels and what is the default trust associated with Sharepoint? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">The Sharepoint Trust Levels has Security and user interaction with the site. 3 types. There are WSS_FULL, WSS_MEDIUM, WSS_MINIMUM.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What are the two logging mechanisms for usage statistics? </span></p>
<ul style="margin-top:0;" type="disc">
<li class="MsoNormal"><span style="font-size:10pt;color:#333333;font-family:Arial;">All default log files are stored in </span><span style="font-size:10pt;font-family:Arial;">\%windir%\system32\LogFiles\STS this path.</span></li>
<li class="MsoNormal"><span style="font-size:10pt;font-family:Arial;">Virtual server Folder. It’s like a cache.</span></li>
</ul>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What functionality does owssup.dll provide for client side activities? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">The owssup.dll is used to create Single Sign On in Sharepoint Portal Server.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 0.5in;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is the difference between a site owner and a site administrator? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Site Owner has only individual site and sub sites access only.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Site Administrator access all site and Central Administration</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is STSAdm and what can it be used for? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 0.5in;"><span style="font-size:10pt;color:#333333;font-family:Arial;">It is used to create/manage sites, lists, web parts etc..</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Can WSS search subsites? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">The Subsite has a unique permission of the parent site, we can search subsite content. Until we can’t search Subsite Content.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Can you register alerts for users? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">No, the admin can give some permission.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Are PDFs searchable?</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:0.25in;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Yes, but default is now. We can use IFILTER type functionality do this moment.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 6pt;"><strong><em><span style="font-size:10pt;color:#333333;font-family:Arial;">SharePoint Architect</span></em></strong></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is a SharePoint farm? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">It is a deployment scenario, we have two are more server to host Sharepoint. It is 3 types.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">1. Small Server, 2. Medium Server, 3. Large Farm.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Describe a large deployment </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:12pt;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;">2 Sharepoint servers 2 SQL Server 1 Search Server 1 Clustering Server. It is called large deployment.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">How can you synchronize custom Active Directory attributes to SharePoint? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Profile Importer from Shared Services Provider.</span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">If it is anticipated that our organization would need to store 1 terabyte of documents, what is the recommended configuration and storage requirement? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">It is based on your users count. </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Describe the implementation of SharePoint and Project Server </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">We can use Project server web parts inside Sharepoint portal server and also create dashboards on Sharepoint pages and can also create custom WebParts using PDC and .Net.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What are the BKMs for workflow and SharePoint? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"><span>                                                    </span></span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Explain how you would deploy SharePoint on an extranet </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Usually servers that are accessible from external sources are housed in DMZ’s. Depending on the requirements and the workflow for publishing content you could go with Multiple Servers hosting the same information. One server would reside inside with the SQL Cluster while the external server resides in the DMZ simply calling data. Security would be handled by the same or different active directory domain clusters as well increasing security.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What is the BKM for maximum number of virtual servers configured for SharePoint on a single box? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:0.25in;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">15 Virtual servers.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What are the migration strategies for moving sites around? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;">You could use the Sharepoint Portal Server backup and restore tool as well as the STSADMIN and GUI STSAMIN tools. We have migrated database from the SQL Level and have simply reconnected the front end.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">What are the archiving strategies? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Describe the search strategies?</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 0 -6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 0 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Can you implement forms-based authentication with SharePoint? </span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:12pt;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;">Yes. We can implement forms-based authentication with SharePoint.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="background:white;text-indent:-0.25in;line-height:14.4pt;margin:0 0 6pt 12pt;"><span style="font-size:10pt;color:#333333;font-family:&quot;"><span>o<span style="font:7pt &quot;">            </span></span></span><span style="font-size:10pt;color:#333333;font-family:Arial;">Describe how single sign-on works</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;">1. Easily maintain Role and group users’ information in one place.</span></p>
<p class="MsoNormal" style="background:white;line-height:14.4pt;margin:0 0 6pt;"><span style="font-size:10pt;color:#333333;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="margin:0 0 6pt;"><span style="font-size:10pt;font-family:Arial;"> </span></p>
<p class="MsoNormal" style="margin:0 0 6pt;"><span style="font-size:10pt;font-family:Arial;"> </span></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/sharepointhelps.wordpress.com/76/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/sharepointhelps.wordpress.com/76/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointhelps.wordpress.com/76/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointhelps.wordpress.com/76/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointhelps.wordpress.com/76/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointhelps.wordpress.com/76/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointhelps.wordpress.com/76/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointhelps.wordpress.com/76/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointhelps.wordpress.com/76/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointhelps.wordpress.com/76/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointhelps.wordpress.com/76/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointhelps.wordpress.com/76/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointhelps.wordpress.com/76/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointhelps.wordpress.com/76/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointhelps.wordpress.com/76/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointhelps.wordpress.com/76/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=76&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointhelps.wordpress.com/2008/08/23/what-a-good-sharepoint-consultant-should-know/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/d80eb71b2c8d6f45fa035457c1d5e8fc?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">vamsankar</media:title>
		</media:content>
	</item>
		<item>
		<title>A base SharePoint web part for AJAX in ASP.NET 3.5</title>
		<link>http://sharepointhelps.wordpress.com/2008/08/08/a-base-sharepoint-web-part-for-ajax-in-aspnet-35/</link>
		<comments>http://sharepointhelps.wordpress.com/2008/08/08/a-base-sharepoint-web-part-for-ajax-in-aspnet-35/#comments</comments>
		<pubDate>Fri, 08 Aug 2008 10:05:14 +0000</pubDate>
		<dc:creator>vamsankar</dc:creator>
				<category><![CDATA[AJAX with Sharepoint]]></category>
		<category><![CDATA[Microsoft Office Sharepoint Server]]></category>
		<category><![CDATA[Windows Sharepoint Services]]></category>

		<guid isPermaLink="false">http://sharepointhelps.wordpress.com/?p=74</guid>
		<description><![CDATA[Introduction This article describe an abstract web part class developed for the SharePoint 2007 (WSS 3.0 or MOSS 2007) platform. The web part contains the logic to address some known conflicts between SharePoint and ASP.NET AJAX and is designed as the base class for all AJAX enabled SharePoint web parts. Background With SharePoint (WSS 3.0 [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=74&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<h2>Introduction</h2>
<p>This article describe an abstract web part class developed for the SharePoint 2007 (WSS 3.0 or MOSS 2007) platform. The web part contains the logic to address some known conflicts between SharePoint and ASP.NET AJAX and is designed as the base class for all AJAX enabled SharePoint web parts.</p>
<h2>Background</h2>
<p>With SharePoint (WSS 3.0 or MOSS 2007) SP1, AJAX is officially supported. However, there are still lots of manual configuration needs to be performed for AJAX to work in the SharePoint environment. Basically you can create an ASP.NET web application targeting .NET framework 3.5 and merge the AJAX related entries into the web.config of your SharePoint application. However, this is not enough. In the MSDN article titled <a href="http://msdn2.microsoft.com/en-us/library/bb861877.aspx">Walkthrough: Creating a Basic ASP.NET AJAX-enabled Web Part</a>, a technique is introduced to fix the conflict between SharePoint and the ASP.NET AJAX UpdatePanel. This article provides a good starting point for developing AJAX enabled SharePoint web part. However, the technique described in the article had its limitations as well. I will go over these limitations below and explained how they can be addressed.</p>
<h2>Using the code</h2>
<p>ASP.NET AJAX requires one instance, and only one instance of the <a href="http://msdn2.microsoft.com/en-us/library/bb398863.aspx">ScriptManager</a> on any page. There are several ways to include the ScriptManager in a SharePoint web part page. One thing you can do is to modify the master page. Another common technique is to detect if an instance of the ScriptManager already exist, and create one on demand if it does not exist. I like the later approach as it is more flexible than modifying the master page, which affects all pages regardless if AJAX is used in the page. After all, there are 3rd party AJAX libraries that are not currently compatible with ASP.NET AJAX, and you may not have full control on all the contents that appears on a portal.</p>
<p>After reviewing the <a href="http://msdn2.microsoft.com/en-us/library/ms178472.aspx">life cycles of an ASP.NET page</a> one more time, I decided to place the logic that creates an instance of the ScriptManager inside the OnInit event, and that seems to work pretty well.</p>
<p>Another issue comes with the &#8220;EnsurePanelFix&#8221; logic, as it too, should not be registered more than once. By creating a common base class for AJAX enabled web part, and register the script using the type of the base web part, the problem can be solved. This is especially good as not only the base web part promotes code reuse, it also fixes problems!</p>
<p>The full code for the web part is included below:</p>
<p><span class="code-keyword">using</span> System;<br />
<span class="code-keyword">using</span> System.Collections.Generic;<br />
<span class="code-keyword">using</span> System.Text;<br />
<span class="code-keyword">using</span> System.Web;<br />
<span class="code-keyword">using</span> System.Web.Services;<br />
<span class="code-keyword">using</span> System.Web.UI;<br />
<span class="code-keyword">using</span> System.ComponentModel;<br />
<span class="code-keyword">using</span> System.Xml.Serialization;<br />
<span class="code-keyword">using</span> System.Web.UI.WebControls;<br />
    <span class="code-keyword">public</span> <span class="code-keyword">abstract</span> <span class="code-keyword">class</span> AjaxBaseWebPart : System.Web.UI.WebControls.WebParts.WebPart<br />
    {<br />
        <span class="code-keyword">protected</span> <span class="code-keyword">override</span> <span class="code-keyword">void</span> OnInit(EventArgs e)<br />
        {<br />
            <span class="code-keyword">base</span>.OnInit(e);<br />
            <span class="code-comment">//</span><span class="code-comment"> Register the ScriptManager</span><br />
            ScriptManager scriptManager = ScriptManager.GetCurrent(<span class="code-keyword">this</span>.Page);<br />
            <span class="code-keyword">if</span> (scriptManager == <span class="code-keyword">null</span>)<br />
            {<br />
                scriptManager = <span class="code-keyword">new</span> ScriptManager();<br />
                scriptManager.ID = <span class="code-string">&#8220;</span><span class="code-string">ScriptManager1&#8243;</span>;<br />
                scriptManager.EnablePartialRendering = <span class="code-keyword">true</span>;<br />
                Controls.AddAt(<span class="code-digit">0</span>, scriptManager);<br />
            }<br />
        }</p>
<p>        <span class="code-keyword">protected</span> <span class="code-keyword">override</span> <span class="code-keyword">void</span> CreateChildControls()<br />
        {<br />
            <span class="code-comment">//</span><span class="code-comment"> Add fix according to http://msdn2.microsoft.com/en-us/library/bb861877.aspx</span><br />
            EnsurePanelFix();<br />
        }</p>
<p>        <span class="code-keyword">private</span> <span class="code-keyword">void</span> EnsurePanelFix()<br />
        {<br />
            <span class="code-keyword">if</span> (<span class="code-keyword">this</span>.Page.Form != <span class="code-keyword">null</span>)<br />
            {<br />
                <span class="code-SDKkeyword">String</span> fixupScript = <span class="code-string">@&#8221;</span><span class="code-string"><br />
     _spBodyOnLoadFunctionNames.push(&#8220;</span><span class="code-string">&#8220;</span><span class="code-string">_initFormActionAjax&#8221;</span><span class="code-string">&#8220;</span><span class="code-string">);<br />
     function _initFormActionAjax()<br />
     {<br />
       if (_spEscapedFormAction == document.forms[0].action)<br />
       {<br />
         document.forms[0]._initialAction =<br />
         document.forms[0].action;<br />
       }<br />
     }<br />
     var RestoreToOriginalFormActionCore =<br />
       RestoreToOriginalFormAction;<br />
     RestoreToOriginalFormAction = function()<br />
     {<br />
       if (_spOriginalFormAction != null)<br />
       {<br />
         RestoreToOriginalFormActionCore();<br />
         document.forms[0]._initialAction =<br />
         document.forms[0].action;<br />
       }<br />
     }&#8221;</span>;<br />
                ScriptManager.RegisterStartupScript(<span class="code-keyword">this</span>,<br />
                  <span class="code-keyword">typeof</span>(AjaxBaseWebPart), <span class="code-string">&#8220;</span><span class="code-string">UpdatePanelFixup&#8221;</span>,<br />
                  fixupScript, <span class="code-keyword">true</span>);<br />
            }<br />
        }<br />
    }</p>
<h2>Points of Interest</h2>
<p>Despite the official support of AJAX in SP1 of SharePoint 2007, it still take lots of effort to start using AJAX in the SharePoint environment. Maybe the next service patch for Visual Studio 2008 will provide the same support for SharePoint development as the support we get for ASP.NET 3.5 AJAX? Let&#8217;s keep our fingers crossed.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/sharepointhelps.wordpress.com/74/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/sharepointhelps.wordpress.com/74/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointhelps.wordpress.com/74/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointhelps.wordpress.com/74/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointhelps.wordpress.com/74/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointhelps.wordpress.com/74/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointhelps.wordpress.com/74/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointhelps.wordpress.com/74/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointhelps.wordpress.com/74/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointhelps.wordpress.com/74/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointhelps.wordpress.com/74/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointhelps.wordpress.com/74/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointhelps.wordpress.com/74/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointhelps.wordpress.com/74/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointhelps.wordpress.com/74/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointhelps.wordpress.com/74/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=74&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointhelps.wordpress.com/2008/08/08/a-base-sharepoint-web-part-for-ajax-in-aspnet-35/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/d80eb71b2c8d6f45fa035457c1d5e8fc?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">vamsankar</media:title>
		</media:content>
	</item>
		<item>
		<title>ASP.NET AJAX and Web Parts in Windows SharePoint Services 3.0</title>
		<link>http://sharepointhelps.wordpress.com/2008/08/08/aspnet-ajax-and-web-parts-in-windows-sharepoint-services-30/</link>
		<comments>http://sharepointhelps.wordpress.com/2008/08/08/aspnet-ajax-and-web-parts-in-windows-sharepoint-services-30/#comments</comments>
		<pubDate>Fri, 08 Aug 2008 07:34:00 +0000</pubDate>
		<dc:creator>vamsankar</dc:creator>
				<category><![CDATA[AJAX with Sharepoint]]></category>
		<category><![CDATA[Microsoft Office Sharepoint Server]]></category>
		<category><![CDATA[Windows Sharepoint Services]]></category>

		<guid isPermaLink="false">http://sharepointhelps.wordpress.com/?p=72</guid>
		<description><![CDATA[You can now extend Microsoft ASP.NET 2.0 by using Microsoft ASP.NET 2.0 AJAX Extensions 1.0, which is a new Microsoft Web development technology that integrates cross-browser script libraries with the ASP.NET 2.0 Web application framework. ASP.NET AJAX allows you to quickly create pages with sophisticated, responsive user interfaces and more efficient client-server communication, simply by [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=72&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>You can now extend Microsoft ASP.NET 2.0 by using Microsoft ASP.NET 2.0 AJAX Extensions 1.0, which is a new Microsoft Web development technology that integrates cross-browser script libraries with the ASP.NET 2.0 Web application framework. ASP.NET AJAX allows you to quickly create pages with sophisticated, responsive user interfaces and more efficient client-server communication, simply by adding a few server controls to your Web pages.</p>
<p>This topic introduces Microsoft ASP.NET AJAX Extensions 1.0 technology in the context of Windows SharePoint Services 3.0. It also provides an overview of the server controls provided with ASP.NET AJAX. For a comprehensive look at the technology behind ASP.NET AJAX, see <a id="ctl00_rs1_mainContentContainer_ctl01" href="http://asp.net/ajax/about/"><span style="color:#0033cc;">About ASP.NET AJAX</span></a>.</p>
<h1 class="heading">Microsoft ASP.NET AJAX</h1>
<div id="sectionSection0" class="seeAlsoNoToggleSection">
<p>ASP.NET AJAX enables you to create Web pages that use partial-page updates to create a dynamic user experience. ASP.NET AJAX includes AJAX Extensions 1.0, which is the server-side control framework, and the Microsoft AJAX Library, which is the set of client-side browser scripts.</p>
<p>The Microsoft AJAX Library can be installed without the .NET Framework. It can also be used in environments that are not Windows-based, to create Web applications for browsers that support JavaScript. See <a id="ctl00_rs1_mainContentContainer_ctl02" href="http://www.asp.net/ajax/downloads/"><span style="color:#800080;">ASP.NET AJAX Downloads</span></a> to download the ASP.NET 2.0 AJAX Extensions 1.0, the Microsoft AJAX Library, and other ASP.NET AJAX components.</div>
<h1 class="heading">Server Controls in Microsoft ASP.NET AJAX</h1>
<div id="sectionSection1" class="seeAlsoNoToggleSection">
<p>ASP.NET 2.0 AJAX Extensions include server-side controls that are used for partial-page updates, as well as progress bars, timers, and script management components. A brief overview of the server-side controls is included here.</p>
<div class="subSection">
<div class="subSection">
<h4 class="subHeading">ScriptManager</h4>
<div class="subSection">
<p>The <strong>ScriptManager</strong> control manages all client script for ASP.NET AJAX. The ScriptManger automatically registers the script for ASP.NET AJAX when you add it to the Web page. You must add this as the first item in the page controls collection. The ScriptManager controls partial-page rendering in a browser when a page contains one or more UpdatePanel controls.</div>
<h4 class="subHeading">UpdatePanel</h4>
<div class="subSection">
<p>The UpdatePanel control stores other controls and allows partial-page updates. The UpdatePanel control allows you to request partial-page updates without writing any client script. You can, however, add custom client-side script if you want to enhance the client user experience. The UpdatePanel and associated triggers are tracked by the ScriptManager control.</p></div>
<h4 class="subHeading">UpdateProgress</h4>
<div class="subSection">
<p>The UpdateProgress control provides status information on partial-page updates in UpdatePanel controls. By default, a <strong>div</strong> element is created and displayed while an update is in progress. You can customize the default display of the <strong>div</strong> control by using the <strong>ProgressTemplate</strong> property.</div>
<h4 class="subHeading">Timer</h4>
<div class="subSection">
<p>The Timer control fires a postback at defined intervals. You can also use the Timer control to post the whole page rather than partial-page updates. Timer controls can be used inside or outside of an UpdatePanel control. If you want the Timer control to trigger an update, you must add a trigger attribute to the UpdatePanel control declaration.</p></div>
</div>
</div>
</div>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/sharepointhelps.wordpress.com/72/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/sharepointhelps.wordpress.com/72/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointhelps.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointhelps.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointhelps.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointhelps.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointhelps.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointhelps.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointhelps.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointhelps.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointhelps.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointhelps.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointhelps.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointhelps.wordpress.com/72/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointhelps.wordpress.com/72/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointhelps.wordpress.com/72/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=72&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointhelps.wordpress.com/2008/08/08/aspnet-ajax-and-web-parts-in-windows-sharepoint-services-30/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/d80eb71b2c8d6f45fa035457c1d5e8fc?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">vamsankar</media:title>
		</media:content>
	</item>
		<item>
		<title>Build web parts with AJAX</title>
		<link>http://sharepointhelps.wordpress.com/2008/08/08/build-web-parts-with-ajax/</link>
		<comments>http://sharepointhelps.wordpress.com/2008/08/08/build-web-parts-with-ajax/#comments</comments>
		<pubDate>Fri, 08 Aug 2008 07:30:18 +0000</pubDate>
		<dc:creator>vamsankar</dc:creator>
				<category><![CDATA[Microsoft Office Sharepoint Server]]></category>
		<category><![CDATA[Windows Sharepoint Services]]></category>

		<guid isPermaLink="false">http://sharepointhelps.wordpress.com/?p=70</guid>
		<description><![CDATA[In this post I’m going to explain how to start using ajax in your web parts.  The goal of this article is to reproduce functionality similar to the KPI and BDC web parts in MOSS 2007.  If you don’t know what ajax is or the basics of how it works this article is probably not [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=70&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">In this post I’m going to explain how to start using ajax in your web parts.<span>  </span>The goal of this article is to reproduce functionality similar to the KPI and BDC web parts in MOSS 2007.<span>  </span>If you don’t know what ajax is or the basics of how it works this article is probably not for you. </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">ASP.net 2.0 has a cool new feature called client script call backs.<span>  </span>Script call backs basically allow you to use javascript to execute a server side method in your assembly and then do something with the result. This allows you to dynamically update parts of the page, or in this case the webpart, without refreshing the entire page.<span>  </span>This article (</span><a href="http://msdn.microsoft.com/msdnmag/issues/04/08/CuttingEdge/"><span style="font-size:small;color:#800080;font-family:Calibri;">http://msdn.microsoft.com/msdnmag/issues/04/08/CuttingEdge/</span></a><span style="font-size:small;font-family:Calibri;">) has a nice explanation of how script call backs work in .net 2.0 but the details of how to actually use it in your code are outdated, so follow the instructions in this post, not the msdn one.<span>  </span>The fact that the script call back feature is built into .net makes it really easy to implement and use. </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">For this example we will pretend that we have a web part that takes a long time to generate its display. To solve this problem we are going to have the render method output a blank div tag when the web part is initially loaded and then replace the contents of the div, via ajax, with the actual content for the webpart. This will allow the page to load and let the user look at everything else on the page while our web part is loading. Lets get started….</span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">Go ahead and create a new web part project. Add the following directive at the top of your web part class…</span></p>
<table class="MsoTableGrid" style="background:#b8cce4;border-collapse:collapse;" border="1" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td style="width:6.65in;background-color:transparent;border:black 1pt solid;padding:0 5.4pt;" width="638" valign="top">
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;">using System.Web.UI;</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-size:small;font-family:Calibri;"> </span></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;"> </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">To let .net know that your class is using script call backs you have to implement the System.Web.UI.ICallbackEventHandler interface….</span></p>
<table class="MsoTableGrid" style="background:#b8cce4;border-collapse:collapse;" border="1" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td style="width:6.65in;background-color:transparent;border:black 1pt solid;padding:0 5.4pt;" width="638" valign="top">
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;">public class TreeViewRollUp : System.Web.UI.ICallbackEventHandler</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-size:small;font-family:Calibri;"> </span></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;"> </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">The ICallBackEventHandler interface has two methods,<span>  </span>public string GetCallbackResult() and public void RaiseCallbackEvent(string eventArgs). We will cover these alittle later on. </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">Now go ahead and add two class variables..</span></p>
<table class="MsoTableGrid" style="background:#b8cce4;border-collapse:collapse;" border="1" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td style="width:6.65in;background-color:transparent;border:black 1pt solid;padding:0 5.4pt;" width="638" valign="top">
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;">private string datadiv; //This will hold the name of your div tag<br />
private string ajaxdata; //This will hold the data that is returned via ajax…</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-size:small;font-family:Calibri;"> </span></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;"> </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">The datadiv variable contains the html id of the div tag we are using to render our contents in. The name of this div tag should be unique per instance of the web part. If it was the same name all the time and you had two instances of the web part on the same page they would replace each others contents.</span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">Now add the following to your render method…</span></p>
<table class="MsoTableGrid" style="background:#b8cce4;border-collapse:collapse;" border="1" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td style="width:6.65in;background-color:transparent;border:black 1pt solid;padding:0 5.4pt;" width="638" valign="top">
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;">this.datadiv = this.ClientID + &#8220;content&#8221;;<span>  </span>//Uses the client side id of the web part instance + a name we give it</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"> </span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;">writer.Write(&#8220;&lt;div id=\&#8221;" + this.datadiv + &#8220;\&#8221;&gt;&lt;img src=\&#8221;_layouts/images/kpiprogressbar.GIF\&#8221; width\&#8221;150\&#8221;&gt;&lt;/div&gt;&#8221;);</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-size:small;font-family:Calibri;"> </span></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;"> </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">You can see in the last line we write the div tag with an image in it. This is just the little progress gif animation that the kpi web parts use. You can replace this with whatever you want and it won’t really affect anything. </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">Now in your OnLoad handler paste the following code…</span></p>
<table class="MsoTableGrid" style="background:#b8cce4;border-collapse:collapse;" border="1" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td style="width:6.65in;background-color:transparent;border:black 1pt solid;padding:0 5.4pt;" width="638" valign="top">
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;">protected override void OnLoad(EventArgs e)</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>        </span>{</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>            </span>this.datadiv = this.ClientID + &#8220;content&#8221;;</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>            </span></span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;">string js = Page.ClientScript.GetCallbackEventReference(this, &#8220;&#8216;blah&#8217;&#8221;, &#8220;filldiv&#8221;, &#8220;&#8216;&#8221; + this.datadiv + &#8220;&#8216;&#8221;, true);</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>            </span></span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;">string contentloader = &#8220;var ajaxcommands=&#8221;;<span>  </span>window.onload = ajaxloader; function ajaxloader () { eval(ajaxcommands); } function filldiv(arg, ctx) { var mydiv = document.getElementById(ctx); mydiv.innerHTML = arg; }&#8221;;<span>     </span></span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"></span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>            </span>if (Page.ClientScript.IsClientScriptBlockRegistered(&#8220;contentloader &#8220;) == false)</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>                </span>Page.ClientScript.RegisterClientScriptBlock(Page.ClientScript.GetType(), &#8220;contentloader&#8221;, contentloader, true);</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"></span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>            </span>Page.ClientScript.RegisterStartupScript(this.GetType(), &#8220;myloader&#8221;, &#8221; ajaxcommands = ajaxcommands + \&#8221;" + js + &#8220;;\&#8221;;&#8221;, true);</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"></span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>            </span>base.OnLoad(e);</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>        </span>}</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-size:small;font-family:Calibri;"> </span></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;"> </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">In this method there are two different blocks of javascript that we are registering. The first string, js, is being set by the GetCallbackEventReference. The GetCallbackEventReference method basically returns the javascript that executes the call back to the server to retrieve the data.<span>  </span>We are passing it a reference to our control (the webpart), “Blah” as some initial data that will get passed back to our assembly when the call back is initiated,<span>  </span>the name of the javascript method to execute once the callback is complete, the name of our div tag as the context, and setting asynchronous to true. The javascript code generated by this will look similar to the following…</span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">WebForm_DoCallback(&#8216;ctl00$m$g_a010b3bd_1a68_40f9_b46b_f87050cf516f&#8217;,'blah&#8217;,filldiv,&#8217;ctl00_m_g_a010b3bd_1a68_40f9_b46b_f87050cf516fcontents&#8217;,null,true);</span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">Now we could stop here and just use this javascript in the OnClick event of a button to initiate the callback to populate the div tag. For this example we don’t want the user to have to click anything to continue loading the web part so we are going to call the WebForm_DoCallback method when the browser loads. That’s what the contentloader string is all about.<span>  </span>The contentloader <span> </span>string declares a javascript variable, ajaxcommands, <span> </span>that holds the command(s) we would like to execute. It also sets the window.onload event to execute the ajaxloader method.<span>  </span>When the ajaxloader <span> </span>method runs it will use the eval function to execute all the commands stored in the ajaxcommands variable. <span> </span>The reason you have to do it this way is because if you have more than once instance of your ajax web part on page both of them will try to use the window.onload event to load their data, which creates a problem because only the last set event handler will execute, not both.<span>  </span>So we set a common method to window.onload event and then each web part just appends its WebForm_DoCallback code to the ajaxcommands variable. <span> </span>This is kind of funky, and I’m sure there is a better way to do it, but it seems to work for me. Finally the contentloader string also includes the filldiv function that gets executed when the call back is completed. The filldiv method simply sets the innerhtml of the div to the contents returned from the callback.</span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">The final step in the OnLoad method of our class is to register the scripts with the page.<span>  </span>Since we only want the contentloader javascript to be rendered once on each page we need to check to see if it has already been registered with the script manager by another webpart on the page. </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">Now all we have left to do is implement the two methods required by the ICallbackEventHandler interface…</span></p>
<table class="MsoTableGrid" style="background:#b8cce4;border-collapse:collapse;" border="1" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td style="width:6.65in;background-color:transparent;border:black 1pt solid;padding:0 5.4pt;" width="638" valign="top">
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-size:small;"><span><span style="font-family:Calibri;">  </span></span><span style="font-family:'Courier New';"><span>     </span>public string GetCallbackResult()</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>        </span>{</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>            </span>return this.ajaxdata;</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>        </span>}</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>        </span>public void RaiseCallbackEvent(string eventArgs)</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>        </span>{</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span> </span><span>           </span>this.ajaxdata = “Some crazy message here!”;</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-family:'Courier New';"><span style="font-size:small;"><span>        </span>}</span></span></p>
<p class="MsoNormal" style="line-height:normal;margin:0;"><span style="font-size:small;font-family:Calibri;"> </span></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;"> </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;"> </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">RaiseCallbackEvent is invoked when the client call back is started.<span>  </span>It is a void method so it doesn’t actually return anything, just sort of gets the data ready for the GetCallbackResult method to return it.<span>   </span>The RaiseCallbackEvent method is where you would put all the code that typically goes in your web parts Render method. In this example we are just going to be sending a simple message back to the client. Go ahead and compile and test it out. </span></p>
<p class="MsoNormal" style="margin:0 0 10pt;"><span style="font-size:small;font-family:Calibri;">Well hopefully this will help you get started using script call backs. Please post comments or suggestions if you have any. </span></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/sharepointhelps.wordpress.com/70/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/sharepointhelps.wordpress.com/70/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointhelps.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointhelps.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointhelps.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointhelps.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointhelps.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointhelps.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointhelps.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointhelps.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointhelps.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointhelps.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointhelps.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointhelps.wordpress.com/70/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointhelps.wordpress.com/70/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointhelps.wordpress.com/70/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=70&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointhelps.wordpress.com/2008/08/08/build-web-parts-with-ajax/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/d80eb71b2c8d6f45fa035457c1d5e8fc?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">vamsankar</media:title>
		</media:content>
	</item>
		<item>
		<title>“Microsoft.SharePoint.SPException: One or more field types are not installed properly.” Using SPQuery</title>
		<link>http://sharepointhelps.wordpress.com/2008/08/06/%e2%80%9cmicrosoftsharepointspexception-one-or-more-field-types-are-not-installed-properly%e2%80%9d-using-spquery/</link>
		<comments>http://sharepointhelps.wordpress.com/2008/08/06/%e2%80%9cmicrosoftsharepointspexception-one-or-more-field-types-are-not-installed-properly%e2%80%9d-using-spquery/#comments</comments>
		<pubDate>Wed, 06 Aug 2008 07:24:49 +0000</pubDate>
		<dc:creator>vamsankar</dc:creator>
				<category><![CDATA[Microsoft Office Sharepoint Server]]></category>
		<category><![CDATA[Windows Sharepoint Services]]></category>

		<guid isPermaLink="false">http://sharepointhelps.wordpress.com/?p=67</guid>
		<description><![CDATA[Have you run into this error? “Microsoft.SharePoint.SPException: One or more field types are not installed properly.” ? Well I did, I was banging my head into the wall, until I realized that the fields had been renamed at some point, and when referencing splistItem[”FieldName”] in my code, it was not recognizing the updated name. So [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=67&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Have you run into this error? “Microsoft.SharePoint.SPException: One or more field types are not installed properly.” ? Well I did, I was banging my head into the wall, until I realized that the fields had been renamed at some point, and when referencing splistItem[”FieldName”] in my code, it was not recognizing the updated name. So make sure you reference either the GUID or the name it was before renaming.</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/sharepointhelps.wordpress.com/67/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/sharepointhelps.wordpress.com/67/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointhelps.wordpress.com/67/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointhelps.wordpress.com/67/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointhelps.wordpress.com/67/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointhelps.wordpress.com/67/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointhelps.wordpress.com/67/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointhelps.wordpress.com/67/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointhelps.wordpress.com/67/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointhelps.wordpress.com/67/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointhelps.wordpress.com/67/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointhelps.wordpress.com/67/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointhelps.wordpress.com/67/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointhelps.wordpress.com/67/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointhelps.wordpress.com/67/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointhelps.wordpress.com/67/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=67&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointhelps.wordpress.com/2008/08/06/%e2%80%9cmicrosoftsharepointspexception-one-or-more-field-types-are-not-installed-properly%e2%80%9d-using-spquery/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/d80eb71b2c8d6f45fa035457c1d5e8fc?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">vamsankar</media:title>
		</media:content>
	</item>
		<item>
		<title>Programmatically uploading multiple files to Custom sharepoint list in 2007</title>
		<link>http://sharepointhelps.wordpress.com/2008/08/06/programmatically-uploading-multiple-files-to-custom-sharepoint-list-in-2007-2/</link>
		<comments>http://sharepointhelps.wordpress.com/2008/08/06/programmatically-uploading-multiple-files-to-custom-sharepoint-list-in-2007-2/#comments</comments>
		<pubDate>Wed, 06 Aug 2008 07:18:07 +0000</pubDate>
		<dc:creator>vamsankar</dc:creator>
				<category><![CDATA[Microsoft Office Sharepoint Server]]></category>
		<category><![CDATA[Windows Sharepoint Services]]></category>

		<guid isPermaLink="false">http://sharepointhelps.wordpress.com/?p=65</guid>
		<description><![CDATA[Introduction:   A custom SharePoint list can be configured to collect any type of data and SharePoint automatically generates the forms for adding new items, editing items and viewing items.   Team Web site comes with a built-in List Calendar, Task, which is listed on the Quick Launch bar. A new custom list has to [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=65&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p class="MsoNormal" style="margin:0;"><span><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';">Introduction:</span></strong></span><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"></span></strong></p>
<p class="MsoNormal" style="margin:0;"><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"> </span></strong></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';" lang="EN">A custom SharePoint list can be configured to collect any type of data and SharePoint automatically generates the forms for adding new items, editing items and viewing items.</span><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"> </span></p>
<p class="MsoNormal" style="margin:0;"><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';">Team Web</span></strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"> site comes with a built-in List Calendar, Task, which is listed on the Quick Launch bar. A new custom list has to be created for storing the files. </span></p>
<p><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"></p>
<p class="MsoNormal" style="margin:0;">
Steps creating custom list:</p>
<p class="MsoNormal" style="margin:0;"> </p>
<p class="MsoNormal" style="margin:0;"><img src="http://sharepointhelps.wordpress.com/wp-admin/Images/1.gif" border="0" alt="" align="baseline" /></p>
<p></span></strong></p>
<p class="MsoNormal" style="margin:0;"> </p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"> </span></p>
<p class="MsoNormal" style="margin:0;"><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';">Custom list created</span></strong></p>
<p class="MsoNormal" style="margin:0;"><strong></strong> </p>
<p class="MsoNormal" style="margin:0;"><strong></strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"><img src="http://sharepointhelps.wordpress.com/wp-admin/Images/2.gif" border="0" alt="" align="baseline" /></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"> </span></p>
<p class="MsoNormal" style="margin:0;"><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';">Custom Column Creation </span></strong></p>
<p><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"><img src="http://sharepointhelps.wordpress.com/wp-admin/Images/3.gif" border="0" alt="" align="baseline" /></span></strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"></span></p>
<ol style="margin-top:0;" type="1">
<li class="MsoNormal"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">While creating custom list Named as FileList default column will create Title.</span></li>
<li class="MsoNormal"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">Modify column name Title as Filename.</span></li>
<li class="MsoNormal"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">Create one more column as Filedate.</span></li>
<li class="MsoNormal"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">Create one more column as FileSize.</span></li>
</ol>
<p class="MsoNormal" style="margin:0;"><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';">Implementation of Web part</p>
<p></span></strong></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';">The files are added to the custom GridView (list) in web part level using browse file upload button. You can add and delete multiple files in this list. Finally all the files are uploaded in custom share point list Filelist using submit button in webpart.</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"> </span></p>
<p class="MsoNormal" style="margin:0;"><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';">The steps to create a web part</span></strong></p>
<ul>
<li>
<div class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:#333333;line-height:115%;font-family:'Verdana','sans-serif';" lang="EN">Make sure installed VS.net 2005.</span></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><span style="font-size:10pt;line-height:115%;font-family:'Verdana','sans-serif';">Make sure installed Web part Project Library in your system.</span></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><em><span style="font-size:10pt;color:#333333;line-height:115%;font-style:normal;font-family:'Verdana','sans-serif';" lang="EN">Start VS.Net 2005 and create a new project.</span></em></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><em></em><em><span style="font-size:10pt;color:#333333;line-height:115%;font-style:normal;font-family:'Verdana','sans-serif';" lang="EN">Select Project Type as Visual C#&#8211;&gt;SharePoint.</span></em></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><em></em><em><span style="font-size:10pt;color:#333333;line-height:115%;font-style:normal;font-family:'Verdana','sans-serif';" lang="EN">Visual Studio Installed templates as Web Part.</span></em></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><em></em><em><span style="font-size:10pt;color:#333333;line-height:115%;font-style:normal;font-family:'Verdana','sans-serif';" lang="EN">Change Name as </span></em><span style="font-size:10pt;line-height:115%;font-family:'Verdana','sans-serif';">MultipleUploadWebpart.</span></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><em><span style="font-size:10pt;color:#333333;line-height:115%;font-style:normal;font-family:'Verdana','sans-serif';" lang="EN">Change Location as e:\</span></em><span style="font-size:10pt;line-height:115%;font-family:'Verdana','sans-serif';" lang="EN"> </span><span style="font-size:10pt;line-height:115%;font-family:'Verdana','sans-serif';">MultipleUploadWebpart.</span></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><span style="font-size:10pt;line-height:115%;font-family:'Verdana','sans-serif';">Change Solution name as FileUploadWebPart.</span></div>
</li>
</ul>
<p class="MsoNormal" style="margin:0;"><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"><img src="http://sharepointhelps.wordpress.com/wp-admin/Images/4.gif" border="0" alt="" align="baseline" /></span></strong></p>
<p class="MsoNormal" style="margin:0;"><strong></strong> </p>
<p class="MsoNormal" style="margin:0;"><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';">Using the Render method</span></strong></p>
<p class="MsoNormal" style="margin:0;"><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"></span></strong> </p>
<p class="MsoNormal" style="vertical-align:top;line-height:140%;margin:0;"><span style="font-size:10pt;color:#333333;line-height:140%;font-family:'Verdana','sans-serif';">The <strong>Web part</strong> base class seals the <strong>Render</strong> method of <strong>System.Web.UI.Control</strong> because the Web Part infrastructure needs to control rendering the contents of a Web Part. For this reason, custom Web Parts must override the <strong>Render</strong> method of the <strong>Web part</strong> base class.</span></p>
<div style="border-right:medium none;border-top:medium none;border-left:medium none;border-bottom:windowtext 1pt solid;padding:0 0 1pt;">
<p class="MsoNormal" style="margin:0;padding:0;"><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"><br />
The Complete Web part Code<br /></span></strong></p>
</div>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"> </span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> File Information</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///&lt;summary&gt;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///</span><span style="font-size:10pt;color:green;font-family:'Verdana','sans-serif';"> &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///</span><span style="font-size:10pt;color:green;font-family:'Verdana','sans-serif';"> Namespace : MultipleFileUploadWebPart</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///</span><span style="font-size:10pt;color:green;font-family:'Verdana','sans-serif';"> </span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///</span><span style="font-size:10pt;color:green;font-family:'Verdana','sans-serif';"> Purpose<span>   </span>: To Create Webpart to programmatically upload MultipleFiles to Custom SharePoint List</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///</span><span style="font-size:10pt;color:green;font-family:'Verdana','sans-serif';"><span>         </span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///</span><span style="font-size:10pt;color:green;font-family:'Verdana','sans-serif';"> Change History</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///</span><span style="font-size:10pt;color:green;font-family:'Verdana','sans-serif';"> &#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///</span><span style="font-size:10pt;color:green;font-family:'Verdana','sans-serif';"> Date<span>    </span><span>        </span>Edit<span>            </span>Author<span>            </span>Comment<span>              </span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///</span><span style="font-size:10pt;color:green;font-family:'Verdana','sans-serif';"> &#8212;&#8212;&#8212;&#8212;-+&#8212;&#8212;&#8211;+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///</span><span style="font-size:10pt;color:green;font-family:'Verdana','sans-serif';"> 12-July-2007<span>    </span>[100]<span>          </span>Saravanan_Gajendran<span>     </span>Create Webpart</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///</span><span style="font-size:10pt;color:green;font-family:'Verdana','sans-serif';"> &#8212;&#8212;&#8212;&#8212;-+&#8212;&#8212;&#8211;+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:gray;font-family:'Verdana','sans-serif';">///&lt;/summary&gt;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> System;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> System.Runtime.InteropServices;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> System.Web.UI;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> System.Web;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> System.Web.UI.WebControls;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> System.Web.UI.HtmlControls;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> System.Web.UI.WebControls.WebParts;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> System.Xml.Serialization;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> System.Data;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> System.IO;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> System.Text;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> System.Web.SessionState;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> Microsoft.SharePoint;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> Microsoft.SharePoint.WebControls;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">using</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> Microsoft.SharePoint.WebPartPages;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> </span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';">namespace</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> MultipleUploadWebpart</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span> </span><span>   </span>[<span style="color:teal;">Guid</span>(<span style="color:maroon;">"2115a405-ff46-4040-8370-6e4fcb7b9194"</span>)]</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>    </span><span> </span><span style="color:blue;">public</span> <span style="color:blue;">class</span> <span style="color:teal;">MultipleUploadWebpart</span> : System.Web.UI.WebControls.WebParts.<span style="color:teal;">WebPart</span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>    </span><span> </span>{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>        </span><span>  </span>#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> Variables</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span>  </span><span style="color:blue;">private</span> <span style="color:teal;">HtmlInputFile</span> inputFile;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span>  </span><span style="color:blue;">private</span> <span style="color:teal;">Button</span> btnUpload;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span>  </span><span style="color:blue;">private</span> <span style="color:teal;">Label</span> lblMessage;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>  </span><span>        </span><span style="color:blue;">private</span> <span style="color:teal;">GridView</span> dgdUpload;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>  </span><span>  </span><span>      </span><span style="color:blue;">private</span> <span style="color:blue;">string</span> fileName = <span style="color:maroon;">&#8220;&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>    </span><span>  </span><span>    </span><span style="color:blue;">private</span> <span style="color:teal;">Button</span> btnSubmit;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>          </span><span style="color:blue;">private</span> <span style="color:teal;">HyperLinkField</span> hlnkFileName;<span>    </span><span>    </span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>      </span><span>  </span><span>  </span><span style="color:blue;">private</span> <span style="color:teal;">BoundField</span> bndFileSize;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>          </span><span style="color:blue;">private</span> <span style="color:teal;">BoundField</span> bndFileKb;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>       </span><span>  </span><span> </span><span style="color:blue;">private</span> <span style="color:teal;">ButtonColumn</span> btnclmDelete;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span>  </span><span style="color:blue;">private</span> <span style="color:teal;">CommandField</span> cmdDelete;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span>  </span><span style="color:blue;">private</span> <span style="color:blue;">double</span> length;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span>  </span><span style="color:blue;">byte</span>[] contents;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>  </span><span>        </span><span style="color:teal;">DataTable</span> dt;<span style="color:green;">//datatable use for multiple file upload</span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>  </span><span>  </span><span>      </span><span style="color:teal;">DataRow</span> dr;<span style="color:green;">//datarow use for multiple file upload</span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>    </span><span>  </span><span>    </span><span style="color:teal;">DataColumn</span> dc;<span style="color:green;">//datacolumn use for multiple file upload</span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>      </span><span>  </span><span>  </span><span style="color:blue;">double</span> count = 0;<span style="color:green;">//count of file size</span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span> </span><span style="color:blue;"><span> </span>#endregion</span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>   </span><span>       </span>#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> Create Child Control</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>   </span><span>  </span><span>     </span><span style="color:blue;">protected</span> <span style="color:blue;">override</span> <span style="color:blue;">void</span> CreateChildControls()</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>     </span><span>  </span><span>   </span>{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span>#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> inputfile</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>           </span><span>   </span><span> </span><span style="color:blue;">this</span>.inputFile = <span style="color:blue;">new</span> <span style="color:teal;">HtmlInputFile</span>();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.inputFile.ID = <span style="color:maroon;">&#8220;_fileUpload&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>           </span><span>   </span><span> </span>#endregion</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>       </span><span>    </span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>   </span><span>            </span>#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> message label</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>   </span><span>   </span><span>         </span><span style="color:blue;">this</span>.lblMessage = <span style="color:blue;">new</span> <span style="color:teal;">Label</span>();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>      </span><span>   </span><span>      </span><span style="color:blue;">this</span>.lblMessage.ID = <span style="color:maroon;">&#8220;_lblMessage&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>         </span><span>   </span><span>   </span><span style="color:blue;">this</span>.lblMessage.Text = <span style="color:maroon;">&#8220;&#8221;</span>;<br />
<span style="color:blue;"><span>            </span><span>   </span>#endregion<br />
<span>   </span><br />
<span> </span><span>   </span><span>           </span>#region</span><span>  </span>Button</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>  </span><span> </span><span style="color:blue;">this</span>.btnUpload = <span style="color:blue;">new</span> <span style="color:teal;">Button</span>();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.btnUpload.ID = <span style="color:maroon;">&#8220;_btnUploadUpload&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>           </span><span>    </span><span style="color:blue;">this</span>.btnUpload.Text = <span style="color:maroon;">&#8220;Upload&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.btnUpload.Click += <span style="color:blue;">new</span> <span style="color:teal;">EventHandler</span>(btnUploadUploadClick);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>    </span><span>           </span><span style="color:blue;">this</span>.btnSubmit = <span style="color:blue;">new</span> <span style="color:teal;">Button</span>();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>    </span><span>   </span><span>        </span><span style="color:blue;">this</span>.btnSubmit.ID = <span style="color:maroon;">&#8220;_btnSubmit&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>       </span><span>   </span><span>     </span><span style="color:blue;">this</span>.btnSubmit.Text = <span style="color:maroon;">&#8220;Submit&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>          </span><span>   </span><span>  </span><span style="color:blue;">this</span>.btnSubmit.Click += <span style="color:blue;">new</span> <span style="color:teal;">EventHandler</span>(btnSubmit_Click);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span>#endregion</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>   </span><span>            </span>#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> GridView</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>   </span><span>   </span><span>         </span><span style="color:blue;">this</span>.dgdUpload = <span style="color:blue;">new</span> <span style="color:teal;">GridView</span>();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>      </span><span>   </span><span>      </span><span style="color:blue;">this</span>.hlnkFileName = <span style="color:blue;">new</span> <span style="color:teal;">HyperLinkField</span>();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>         </span><span>   </span><span>   </span><span style="color:blue;">this</span>.hlnkFileName.DataTextField = <span style="color:maroon;">&#8220;FileName&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.hlnkFileName.DataNavigateUrlFormatString = <span style="color:maroon;">&#8220;FilePath&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>           </span><span>   </span><span> </span><span style="color:blue;">this</span>.hlnkFileName.HeaderText = <span style="color:maroon;">&#8220;FileName&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>    </span><span>           </span><span style="color:blue;">this</span>.bndFileSize = <span style="color:blue;">new</span> <span style="color:teal;">BoundField</span>();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>    </span><span>   </span><span>        </span><span style="color:blue;">this</span>.bndFileSize.HeaderText = <span style="color:maroon;">&#8220;FileSize&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>       </span><span>   </span><span>     </span><span style="color:blue;">this</span>.bndFileSize.DataField = <span style="color:maroon;">&#8220;FileSize&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>   </span><span>            </span><span style="color:blue;">this</span>.bndFileKb = <span style="color:blue;">new</span> <span style="color:teal;">BoundField</span>();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>   </span><span>  </span><span> </span><span> </span><span>        </span><span style="color:blue;">this</span>.bndFileKb.HeaderText = <span style="color:maroon;">&#8220;&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>     </span><span> </span><span> </span><span>  </span><span>      </span><span style="color:blue;">this</span>.bndFileKb.DataField = <span style="color:maroon;">&#8220;KB&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>   </span><span>            </span><span style="color:blue;">this</span>.cmdDelete = <span style="color:blue;">new</span> <span style="color:teal;">CommandField</span>();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>   </span><span>   </span><span>         </span><span style="color:blue;">this</span>.cmdDelete.HeaderText = <span style="color:maroon;">&#8220;Delete&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>      </span><span>   </span><span>      </span><span style="color:blue;">this</span>.cmdDelete.ButtonType = <span style="color:teal;">ButtonType</span>.Link;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>         </span><span>   </span><span>   </span><span style="color:blue;">this</span>.cmdDelete.InsertImageUrl = <span style="color:maroon;">&#8220;delete.gif&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.cmdDelete.DeleteText = <span style="color:maroon;">&#8220;Delete&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.cmdDelete.ShowDeleteButton = <span style="color:blue;">true</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>               </span><span style="color:blue;">this</span>.dgdUpload.ID = <span style="color:maroon;">&#8220;_dgdFileUpload&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.dgdUpload.Columns.Add(hlnkFileName);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.dgdUpload.Columns.Add(bndFileSize);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.dgdUpload.Columns.Add(bndFileKb);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.dgdUpload.Columns.Add(cmdDelete);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>               </span><span style="color:blue;">this</span>.dgdUpload.AutoGenerateColumns = <span style="color:blue;">false</span>;<span>           </span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.dgdUpload.RowDeleting += <span style="color:blue;">new </span><span style="color:teal;">GridViewDeleteEventHandler<br />
               </span>(dgdUpload_RowDeleting);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span>#endregion</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span>#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> Add Controls</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>           </span><span>   </span><span> </span><span style="color:blue;">this</span>.Controls.Add(dgdUpload);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.Controls.Add(inputFile);<br />
<span>            </span><span>   </span><span style="color:blue;">this</span>.Controls.Add(lblMessage);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>           </span><span>    </span><span style="color:blue;">this</span>.Controls.Add(btnUpload);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">this</span>.Controls.Add(btnSubmit);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>   </span><span style="color:blue;">base</span>.CreateChildControls();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>           </span><span>   </span><span> </span>#endregion</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span>  </span>}</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>        </span><span>  </span>#endregion</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>        </span><span>  </span>#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> RowDeleting</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>      </span><span>  </span><span>  </span><span style="color:blue;">private</span> <span style="color:blue;">void</span> dgdUpload_RowDeleting(<span style="color:blue;">object</span> sender, <span style="color:teal;">GridViewDeleteEventArgs</span> e)</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span>  </span>{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>          </span><span>     </span><span style="color:blue;">int</span> recordToDelete= e.RowIndex;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>           </span><span>    </span>dt = (<span style="color:teal;">DataTable</span>)Page.Session[<span style="color:maroon;">"Files"</span>];</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>           </span><span>    </span><span style="color:blue;">int</span> cn = dt.Rows.Count;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>           </span><span>    </span>dt.Rows.RemoveAt(recordToDelete);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>           </span><span>    </span>dt.AcceptChanges();<br />
<span>               </span>Page.Session[<span style="color:maroon;">"Files"</span>] = dt;<br />
<span>               </span><span style="color:blue;">this</span>.dgdUpload.DataSource = dt<br />
<span>               </span><span style="color:blue;">this</span>.dgdUpload.DataBind();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>       </span><span>    </span>}</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>      </span><span>    </span><span> </span>#endregion</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>    </span><span>  </span><span style="color:blue;"><span>     </span>#region</span> OnLoad</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>      </span><span> </span><span>  </span><span>  </span><span style="color:blue;">protected</span> <span style="color:blue;">override</span> <span style="color:blue;">void</span> OnLoad(<span style="color:teal;">EventArgs</span> e)</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span>   </span>{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>    </span><span style="color:blue;">base</span>.OnLoad(e);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>       </span><span>    </span>}</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>    </span><span>       </span>#endregion</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>    </span><span>       </span>#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> File in SharePoint List</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>    </span><span>   </span><span>    </span><span style="color:blue;">private</span> <span style="color:blue;">void</span> btnSubmit_Click(<span style="color:blue;">object</span> sender, <span style="color:teal;">EventArgs</span> e)</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>       </span><span>    </span>{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>    </span><span>        </span><span>    </span><span style="color:teal;">SPWeb</span> site = <span style="color:teal;">SPContext</span>.Current.Web;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>    </span><span style="color:teal;">SPList</span> list = site.Lists[<span style="color:maroon;">"FileList"</span>];</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>    </span><span style="color:teal;">SPListItem</span> myNewItem ;<span>           </span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>                </span>dt = (<span style="color:teal;">DataTable</span>)Page.Session[<span style="color:maroon;">"Files"</span>];</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>           </span><span>     </span><span style="color:blue;">int</span> _dtcnt = dt.Rows.Count;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>     </span><span>           </span><span style="color:blue;">string</span> strDate=<span style="color:maroon;">&#8220;&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>           </span><span>    </span><span> </span><span style="color:blue;">foreach</span> (<span style="color:teal;">DataRow</span> dr <span style="color:blue;">in</span> dt.Rows)</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span>{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>                </span><span> </span>strDate = System.<span style="color:teal;">DateTime</span>.Now.Date.TimeOfDay.ToString();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>                </span><span> </span>myNewItem = list.Items.Add();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>               </span><span> </span><span> </span>fileName = dr[<span style="color:maroon;">"Filename"</span>].ToString();<span>               </span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>               </span><span> </span><span> </span><span style="color:blue;">string</span> strFilepath= dr[<span style="color:maroon;">"FilePath"</span>].ToString()</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>                </span><span> </span><span style="color:teal;">StreamReader</span> sr = <span style="color:blue;">new</span> <span style="color:teal;">StreamReader</span>(strFilepath);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>                </span><span> </span><span style="color:teal;">Stream</span> fStream=sr.BaseStream ;<span>                </span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>                 </span>contents = <span style="color:blue;">new</span> <span style="color:blue;">byte</span>[fStream.Length];</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>                </span><span> </span>fStream.Read(contents, 0, (<span style="color:blue;">int</span>)fStream.Length);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>               </span><span> </span><span> </span>fStream.Close();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>               </span><span> </span><span> </span>myNewItem[<span style="color:maroon;">"Filename"</span>] = dr[<span style="color:maroon;">"Filename"</span>].ToString();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>               </span><span> </span><span> </span>myNewItem[<span style="color:maroon;">"FileSize"</span>] = dr[<span style="color:maroon;">"FileSize"</span>].ToString();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span>  </span><span>              </span>myNewItem[<span style="color:maroon;">"Filedate"</span>] = strDate;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span>                </span>myNewItem.Attachments.Add(fileName, contents);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span> </span><span>               </span>myNewItem.Update();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>                 </span>System.IO.<span style="color:#2b91af;">File</span>.Delete(strFilepath);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>             </span>}</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span>            </span>lblMessage.Text = <span style="color:maroon;">&#8220;Sucessfully Submited&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span>         </span><span>   </span>}</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>        </span><span>     </span>#endregion</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>     </span><span>        </span>#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> Upload File Add in List</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>     </span><span>     </span><span>   </span><span style="color:blue;">protected</span> <span style="color:blue;">void</span> btnUploadUploadClick(<span style="color:blue;">object</span> sender, <span style="color:teal;">EventArgs</span> e)</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span>     </span>{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>             </span><span>     </span>fileName = System.IO.<span style="color:teal;">Path</span>.GetFileName(inputFile.PostedFile.FileName);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span>      </span><span style="color:blue;">if</span> (fileName != <span style="color:maroon;">&#8220;&#8221;</span>)</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span> </span>{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>              </span><span>    </span><span style="color:blue;">string</span> _fileTime = <span style="color:teal;">DateTime</span>.Now.ToFileTime().ToString();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>                  </span>string</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> _fileorgPath = <span> </span>System.IO.<span style="color:teal;">Path</span>.GetFullPath<br />
                  (inputFile.PostedFile.FileName);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>     </span><span>           </span><span>  </span><span style="color:blue;">string</span> _newfilePath = _fileTime + <span style="color:maroon;">&#8220;~&#8221;</span> + fileName;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>   </span><span>               </span>length = (inputFile.PostedFile.InputStream.Length) / 1024;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>                  </span><span style="color:blue;">string</span> tempFolder = <span style="color:teal;">Environment</span>.GetEnvironmentVariable(<span style="color:maroon;">&#8220;TEMP&#8221;</span>);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>   </span><span>   </span><span>            </span><span style="color:blue;">string</span> _filepath = tempFolder + _newfilePath;<span>                </span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>      </span><span>  </span><span>          </span>inputFile.PostedFile.SaveAs(_filepath);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>   </span><span>               </span>AddRow(fileName, _filepath, length);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>   </span><span>  </span><span>             </span>lblMessage.Text = <span style="color:maroon;">&#8220;Successfully Added in List&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span> </span>}</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span> </span><span style="color:blue;">else<br />
<span>  </span></span><span>           </span>{<span style="color:blue;"></span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>                </span><span>  </span>lblMessage.Text=<span style="color:maroon;">&#8220;Select a File&#8221;</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>              </span><span>  </span><span>  </span><span style="color:blue;">return</span>;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span> </span>}</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span>}</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>        </span>#endregion</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>        </span>#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> Render </span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span style="color:blue;">protected</span> <span style="color:blue;">override</span> <span style="color:blue;">void</span> Render(<span style="color:teal;">HtmlTextWriter</span> writer)</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span>{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>         </span><span> </span><span>   </span><span style="color:green;">// TODO: add custom rendering code here.</span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>         </span><span> </span><span>   </span>EnsureChildControls();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>          </span><span> </span><span>  </span><span style="color:blue;">this</span>.inputFile.RenderControl(writer);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>           </span><span> </span><span> </span><span style="color:blue;">this</span>.btnUpload.RenderControl(writer);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span> </span><span style="color:blue;">this</span>.lblMessage.RenderControl(writer);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span> </span><span style="color:blue;">this</span>.dgdUpload.RenderControl(writer);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span> </span><span style="color:blue;">this</span>.btnSubmit.RenderControl(writer);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span>}</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>        </span>#endregion</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>        </span>#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> AddMoreRows for file upload</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span>       </span><span style="color:blue;">private</span> <span style="color:blue;">void</span> AddMoreColumns()</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span> </span><span>      </span>{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>  </span><span>    </span><span>       </span>dt = <span style="color:blue;">new</span> <span style="color:teal;">DataTable</span>(<span style="color:maroon;">&#8220;Files&#8221;</span>);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span>            </span>dc = <span style="color:blue;">new</span> <span style="color:teal;">DataColumn</span>(<span style="color:maroon;">&#8220;FileName&#8221;</span>, <span style="color:teal;">Type</span>.GetType(<span style="color:maroon;">&#8220;System.String&#8221;</span>));</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span> </span><span>           </span>dt.Columns.Add(dc);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span>            </span>dc = <span style="color:blue;">new</span> <span style="color:teal;">DataColumn</span>(<span style="color:maroon;">&#8220;FilePath&#8221;</span>, <span style="color:teal;">Type</span>.GetType(<span style="color:maroon;">&#8220;System.String&#8221;</span>));</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span>  </span><span>          </span>dt.Columns.Add(dc);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>  </span><span>           </span>dc = <span style="color:blue;">new</span> <span style="color:teal;">DataColumn</span>(<span style="color:maroon;">&#8220;FileSize&#8221;</span>, <span style="color:teal;">Type</span>.GetType(<span style="color:maroon;">&#8220;System.String&#8221;</span>));</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>  </span><span> </span><span>          </span>dt.Columns.Add(dc);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span>            </span>dc = <span style="color:blue;">new</span> <span style="color:teal;">DataColumn</span>(<span style="color:maroon;">&#8220;KB&#8221;</span>, <span style="color:teal;">Type</span>.GetType(<span style="color:maroon;">&#8220;System.String&#8221;</span>));</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span> </span><span>           </span>dt.Columns.Add(dc);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>  </span><span> </span><span>          </span>Page.Session[<span style="color:maroon;">"Files"</span>] = dt; </span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>   </span><span>     </span>}</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>        </span>#endregion</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>        </span>#region</span><span style="font-size:10pt;font-family:'Verdana','sans-serif';"> AddRow for file upload</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span style="color:blue;">private</span> <span style="color:blue;">void</span> AddRow(<span style="color:blue;">string</span> file, <span style="color:blue;">string</span> path, <span style="color:blue;">double</span> length)</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span>{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span> </span>dt = (<span style="color:teal;">DataTable</span>)Page.Session[<span style="color:maroon;">"Files"</span>];</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>         </span><span> </span><span>   </span><span style="color:blue;">if</span> (dt == <span style="color:blue;">null</span>)</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span>{</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>                </span><span> </span>AddMoreColumns();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span>}</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span>dr = dt.NewRow();</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span>dr[<span style="color:maroon;">"FileName"</span>] = file;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span>dr[<span style="color:maroon;">"FilePath"</span>] = path;<span>           </span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span> </span><span>           </span>dr[<span style="color:maroon;">"FileSize"</span>] = <span style="color:teal;">Convert</span>.ToString(length);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span>dr[<span style="color:maroon;">"KB"</span>] = <span style="color:maroon;">&#8220;KB&#8221;</span>;<span>          </span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span>dt.Rows.Add(dr);</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span>Page.Session[<span style="color:maroon;">"Files"</span>] = dt;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>        </span><span>    </span><span style="color:blue;">this</span>.dgdUpload.DataSource = dt;</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>            </span><span style="color:blue;">this</span>.dgdUpload.DataBind();<span style="color:green;">//bind in grid</span></span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>       </span>}</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;color:blue;font-family:'Verdana','sans-serif';"><span>       </span>#endregion</span></p>
<p class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';"><span>  </span><span> </span>}<br />
}</span></p>
<p class="MsoNormal" style="margin:0;"> </p>
<p><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';"></p>
<p class="MsoNormal" style="margin:0;"> </p>
<p><strong><span style="font-size:10pt;color:black;font-family:'Verdana','sans-serif';">Deploy File Upload Web part in the share point server</span></strong><span></p>
<ol>
<li>
<div class="MsoNormal" style="margin:0;">Right click solution file then select properties. </div>
</li>
</ol>
<p></span></span></strong></p>
<ol>
<li></li>
<li>
<div class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">Select Debug Start browser with URL selects your respective SharePoint Site.</p>
<p><img src="http://sharepointhelps.wordpress.com/wp-admin/Images/5.gif" border="0" alt="" align="baseline" /><br />
</span></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">Select Signing option.</p>
<p><img src="http://sharepointhelps.wordpress.com/wp-admin/Images/6.gif" border="0" alt="" align="baseline" /><br />
</span></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">Ensure the strong name key and sign the assembly check box.</span></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">Right Click properties select Deploy.</p>
<p><img src="http://sharepointhelps.wordpress.com/wp-admin/Images/7.gif" border="0" alt="" align="baseline" /><br />
</span></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">It is automatically deployed the web part in respective site.</span></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">Deploy will take care of .Stop IIS, Buliding solution, Restarting Solution, Creating GAC, Restarting IIS like that.</p>
<p><img src="http://sharepointhelps.wordpress.com/wp-admin/Images/8.gif" border="0" alt="" align="baseline" /><br />
</span></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">Multiple Upload Webpart is new one.</span></div>
</li>
<li>
<div class="MsoNormal" style="margin:0;"><span style="font-size:10pt;font-family:'Verdana','sans-serif';">New MultipleUploadWebpart Web Part.</p>
<p><img src="http://sharepointhelps.wordpress.com/wp-admin/Images/9.gif" border="0" alt="" align="baseline" /></span></div>
</li>
</ol>
<p><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';" lang="EN">Events</span></strong></p>
<p><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';" lang="EN">1. Browse Button</p>
<p></span></strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';" lang="EN">It is used to browse and select the particular file.<strong></p>
<p>2. Upload Button</p>
<p></strong>It is used to upload file to the windows temp folder then list the files.<strong></strong></span></p>
<p><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';" lang="EN">3. Submit Button</p>
<p></span></strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';" lang="EN">It is used to store all files in share point custom list.</span></p>
<p><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';" lang="EN"><img src="http://sharepointhelps.wordpress.com/wp-admin/Images/10.gif" border="0" alt="" align="baseline" /></p>
<p>All the files are listed </span></p>
<p><strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';" lang="EN">Delete</p>
<p></span></strong><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';" lang="EN">using this option you need to delete the file in this list.Whenever you give the submit only it will go to SharePoint list.</span></p>
<p><span style="font-size:10pt;color:#333333;font-family:'Verdana','sans-serif';" lang="EN"><img src="http://sharepointhelps.wordpress.com/wp-admin/Images/11.gif" border="0" alt="" align="baseline" /></p>
<p>All the files are uploading in respective share point custom list.</span></p>
<p class="MsoNormal" style="margin:0;"> </p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/sharepointhelps.wordpress.com/65/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/sharepointhelps.wordpress.com/65/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointhelps.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointhelps.wordpress.com/65/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointhelps.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointhelps.wordpress.com/65/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointhelps.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointhelps.wordpress.com/65/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointhelps.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointhelps.wordpress.com/65/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointhelps.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointhelps.wordpress.com/65/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointhelps.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointhelps.wordpress.com/65/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointhelps.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointhelps.wordpress.com/65/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=65&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointhelps.wordpress.com/2008/08/06/programmatically-uploading-multiple-files-to-custom-sharepoint-list-in-2007-2/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/d80eb71b2c8d6f45fa035457c1d5e8fc?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">vamsankar</media:title>
		</media:content>

		<media:content url="http://sharepointhelps.wordpress.com/wp-admin/Images/1.gif" medium="image" />

		<media:content url="http://sharepointhelps.wordpress.com/wp-admin/Images/2.gif" medium="image" />

		<media:content url="http://sharepointhelps.wordpress.com/wp-admin/Images/3.gif" medium="image" />

		<media:content url="http://sharepointhelps.wordpress.com/wp-admin/Images/4.gif" medium="image" />

		<media:content url="http://sharepointhelps.wordpress.com/wp-admin/Images/5.gif" medium="image" />

		<media:content url="http://sharepointhelps.wordpress.com/wp-admin/Images/6.gif" medium="image" />

		<media:content url="http://sharepointhelps.wordpress.com/wp-admin/Images/7.gif" medium="image" />

		<media:content url="http://sharepointhelps.wordpress.com/wp-admin/Images/8.gif" medium="image" />

		<media:content url="http://sharepointhelps.wordpress.com/wp-admin/Images/9.gif" medium="image" />

		<media:content url="http://sharepointhelps.wordpress.com/wp-admin/Images/10.gif" medium="image" />

		<media:content url="http://sharepointhelps.wordpress.com/wp-admin/Images/11.gif" medium="image" />
	</item>
		<item>
		<title>The Long Path to Content Deployment</title>
		<link>http://sharepointhelps.wordpress.com/2008/08/06/the-long-path-to-content-deployment/</link>
		<comments>http://sharepointhelps.wordpress.com/2008/08/06/the-long-path-to-content-deployment/#comments</comments>
		<pubDate>Wed, 06 Aug 2008 07:14:24 +0000</pubDate>
		<dc:creator>vamsankar</dc:creator>
				<category><![CDATA[Microsoft Office Sharepoint Server]]></category>
		<category><![CDATA[Windows Sharepoint Services]]></category>

		<guid isPermaLink="false">http://sharepointhelps.wordpress.com/2008/08/06/the-long-path-to-content-deployment/</guid>
		<description><![CDATA[Recently I’ve had the pleasure to use the content deployment feature of MOSS between some of our SharePoint environments. It was not a smooth ride and I believe that I have now met every single obstacle and bug in that feature. This posting is the result of several months’ worth of frustration. We got three [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=64&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Recently I’ve had <span style="text-decoration:line-through;">the pleasure</span> to use the content deployment feature of MOSS between some of our SharePoint environments.</p>
<p>It was not a smooth ride and I believe that I have now met every single obstacle and bug in that feature. This posting is the result of several months’ worth of frustration.</p>
<p>We got three environments Dev, Test and Prod and we want to use content deployment to move content from the production servers to the development and test servers, simply to ensure current test data.</p>
<p>As a side node, you might want to read the Microsoft brief “<a href="http://msdn2.microsoft.com/en-us/library/bb428899.aspx"><span style="color:#909d73;">Team-based Development in Microsoft Office SharePoint Server 2007</span></a>” for another good reason to make content deployment one of your skills.</p>
<p>Well, without beating around the bush anymore the following are the steps needed to do a content deployment (with some minor obvious exceptions) in order of appearance.</p>
<h1>Setup path</h1>
<p>Content deployment requires you to first setup a <em>path</em> and then one or more <em>jobs</em> for that path. Simply put the <em>path</em> is the server to server connection configuration, the <em>job</em> is a specification of what to do and when.</p>
<p>I try to use security best practices so all my both service users are just standard domain users, any special rights they might need are assigned by MOSS during the configuration wizard. In the same vein my farm administrator accounts are standard domain users that are assigned extra permissions only through SharePoint.</p>
<p style="text-align:center;"> </p>
<p>The first problem with creating a path is an access denied problem during the path setup page (/_admin/DeploymentPath.aspx), when you select the <em>source</em> web application and site collection. For the destination site collection you are required to provide an explicit user with sufficient rights.</p>
<p style="text-align:center;"><img src="http://soerennielsen.files.wordpress.com/2007/06/061907-2220-thelongpath1.png?w=450" alt="" /></p>
<p style="text-align:center;"><span style="font-size:9pt;color:#4f81bd;"><strong>Figure 1: The “Access denied” message<br />
</strong></span></p>
<p>It seems that your logged in user needs to be able to read the IIS metabase when you select a web application. There are many ways to grant access, I choose to add my farm administrator to the IIS_WPG local security group on the server. In my opinion the SharePoint team forgot to impersonate the call to read the IIS metadata. Will hopefully be fixed in some future service pack.</p>
<p>The second problem (on the very same page) occurs if you connect to another farm using SSL (which you should!) – You get the exception “Requested registry access not allowed” when you submit the page.</p>
<p>After some tracing I’ve learned that the problem is that the server tries to store the SSL key for your destination server in the registry hive for the system user, which is the correct one, but apparently the SharePoint configuration wizard tightened the security on the keys in question.</p>
<p>To get around this: Grant your user (farm admin) membership to the local WSS_RESTRICTED_WPG security group and grant that group “full control” to HKEY_USERS\.DEFAULT\Software\Microsoft\SystemCertificates. You could also opt for granting your user direct access to the key.</p>
<p>To sum it up:</p>
<ol>
<li>Your logged in user should be a farm administrator</li>
<li>Should be a member of either the local IIS_WPG or WSS_WPG groups</li>
<li>Grant access to HKEY_USERS\.DEFAULT\Software\Microsoft\SystemCertificates
<ol>
<li>Add user to WSS_RESTRICTED_WPG group</li>
<li>Grant that group “full control” access to the key</li>
</ol>
</li>
</ol>
<p>That’s it! You should now be able to setup a path.</p>
<h1>Setup Job</h1>
<p>Next setup the job to your liking, choose whatever options you desire.</p>
<p>Run the job. If it succeeds then stop reading now and save a few minutes of your time. No? Carry on then…</p>
<h1>Hotfix deployment</h1>
<p>At this point I got the following exception:</p>
<p><span style="font-size:9pt;color:red;">User cannot be found. at Microsoft.SharePoint.SPUserCollection.GetByID(Int32 id) at Microsoft.SharePoint.SPWeb.get_Author() at Microsoft.SharePoint.Deployment.WebSerializer.GetDataFromObjectModel(Object obj, SerializationInfo info, StreamingContext context) at Microsoft.SharePoint.Deployment.DeploymentSerializationSurrogate.GetObjectData(Object obj, SerializationInfo info, StreamingContext context) at Microsoft.SharePoint.Deployment.XmlFormatter.SerializeObject(Object obj, ISerializationSurrogate surrogate, String elementName, Boolean bNeedEnvelope) at Microsoft.SharePoint.Deployment.XmlFormatter.Serialize(Stream serializationStream, Object topLevelObject) at Microsoft.SharePoint.Deployment.ObjectSerializer.Serialize(DeploymentObject deployObject, Stream serializationStream) at Microsoft.SharePoint.Deployment.SPExport.SerializeObjects() at Microsoft.SharePoint.Deployment.SPExport.Run()<br />
</span></p>
<p>Looking like this:</p>
<p style="text-align:center;"><img src="http://soerennielsen.files.wordpress.com/2007/06/061907-2220-thelongpath2.png?w=450" alt="" /></p>
<p style="text-align:center;"><span style="color:#4f81bd;"><strong><span style="font-size:9pt;">Figure 2: Deployment error &#8211; no creator/owner of site</span><span style="font-size:12pt;font-family:Times New Roman;"><br />
</span></strong></span></p>
<p>The exception occurs fairly quickly during the preparation phase. It obviously indicates that a creator of a (sub) site it not to be found in the SharePoint user database.</p>
<p>In my case it happened because the farm was originally deployed using a site collection backup/restore from another AD domain, the creators of various sites would then be users in the original SharePoint farm which would be unknown in the new (which is now my source). I suppose you might see this error if you deleted some users as well.</p>
<p>There is nothing you can do about this error; Microsoft however, has a hotfix for this (which also solves a few other bugs). Hotfix number is 313183 and the knowledge base article you are trying to address is kb936867. At the moment of writing this is private hotfix that can only be obtained by contacting MS support. Sucks but there is a way at least.</p>
<p>The hotfix solves a total of 11 bugs including one more in relation to Content Deployment entitled “Violation of PRIMARY KEY” – it seems I avoided one snag after all.</p>
<h1>Feature problems</h1>
<p>Next error in line occurred right after the last during the export phase. I received the very informative exception:</p>
<p><span style="font-size:9pt;color:red;">Failed to compare two elements in the array.<br />
at System.Collections.Generic.ArraySortHelper`1.QuickSort[TValue](T[] keys, TValue[] values, Int32 left, Int32 right, IComparer`1 comparer)<br />
at System.Collections.Generic.ArraySortHelper`1.QuickSort[TValue](T[] keys, TValue[] values, Int32 left, Int32 right, IComparer`1 comparer)<br />
at System.Collections.Generic.ArraySortHelper`1.QuickSort[TValue](T[] keys, TValue[] values, Int32 left, Int32 right, IComparer`1 comparer)<br />
at System.Collections.Generic.ArraySortHelper`1.Sort[TValue](T[] keys, TValue[] values, Int32 index, Int32 length, IComparer`1 comparer)<br />
at System.Collections.Generic.ArraySortHelper`1.Sort(T[] items, Int32 index, Int32 length, IComparer`1 comparer)<br />
at System.Array.Sort[T](T[] array, Int32 index, Int32 length, IComparer`1 comparer)<br />
at System.Collections.Generic.List`1.Sort(Int32 index, Int32 count, IComparer`1 comparer)<br />
at System.Collections.Generic.List`1.Sort(IComparer`1 comparer)<br />
at Microsoft.SharePoint.Deployment.WebSerializer.GetDataFromObjectModel(Object obj, SerializationInfo info, StreamingContext context)<br />
at Microsoft.SharePoint.Deployment.DeploymentSerializationSurrogate.GetObjectData(Object obj, SerializationInfo info, StreamingContext context)<br />
at Microsoft.SharePoint.Deployment.XmlFormatter.SerializeObject(Object obj, ISerializationSurrogate surrogate, String elementName, Boolean bNeedEnvelope)<br />
at Microsoft.SharePoint.Deployment.XmlFormatter.Serialize(Stream serializationStream, Object topLevelObject)<br />
at Microsoft.SharePoint.Deployment.ObjectSerializer.Serialize(DeploymentObject deployObject, Stream serializationStream)<br />
at Microsoft.SharePoint.Deployment.SPExport.SerializeObjects()<br />
at Microsoft.SharePoint.Deployment.SPExport.Run()<br />
*** Inner exception:<br />
Object reference not set to an instance of an object.<br />
at Microsoft.SharePoint.SPFeature.EnsureProperties()<br />
at Microsoft.SharePoint.SPFeature.get_TimeActivated()<br />
at Microsoft.SharePoint.Deployment.WebSerializer.ExportFeatureComparer.System.Collections.Generic.IComparer .Compare(ExportObject exportObject1, ExportObject exportObject2)<br />
at System.Collections.Generic.ArraySortHelper`1.QuickSort[TValue](T[] keys, TValue[] values, Int32 left, Int32 right, IComparer`1 comparer)<br />
</span></p>
<p>Going to the source server I tried to pinpoint the error by running “stsadm –o export …” on the base site collection url (same error) and then the first level of sub sites (all exported fine).</p>
<p>That command is exactly the same as a content deployment just without the transfer and import part on the destination end (you are responsible for transfer and then use the import command).</p>
<p>The exception basically means that some of the features activated at the site collection level no longer exist on disk. Their feature definition files have probably been deleted. This can easily occur if you delete some features from your solution packs without deactivating/reactivating all features on deployment (and who cares to do that?).</p>
<p>If you know exactly what features are the problem (might be more than you know) I suppose you might be able to reinstall, deactivate and then uninstall to fix the problem. You might also be able to create dummy features with the correct ids and then try to install, deactivate and uninstall.</p>
<p>I did neither; code had to be written <span style="font-family:Wingdings;"><img class="wp-smiley" src="http://s.wordpress.com/wp-includes/images/smilies/icon_wink.gif" alt=";-)" /> </span></p>
<p>What you need to do is:</p>
<ol>
<li>Go recursively through your web application / site collection / root web / web</li>
<li>Each of these “parent” objects have a Feature collection</li>
<li>Each of these features in the feature collection should be examined
<ol>
<li>If there is no <em>feature</em>.Definition (== null) then this is one of the faulty features.Simple remove it by executing <em>parent</em>.Features.Remove( <em>id</em>, true ). The force parameter is needed since the feature is not properly installed anymore, so you just remove it without any knowledge of deactivation event handlers etc.</li>
</ol>
</li>
</ol>
<p>I wrote an aspx page for this that is installed as a feature in the Central Administration site:</p>
<p style="text-align:center;"><img src="http://soerennielsen.files.wordpress.com/2007/06/061907-2220-thelongpath3.png?w=450" alt="" /></p>
<p style="text-align:center;"><span style="font-size:9pt;color:#4f81bd;"><strong>Figure 3: My page to list and possibly remove features from web app / site / web<br />
</strong></span></p>
<p>Pretty cool <span style="font-family:Wingdings;"><img class="wp-smiley" src="http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif" alt="-)" /> </span></p>
<p>In due time, I will clean up the code and publish another article about this administration feature along with a few others that I’ve developed and since found indispensable.</p>
<h1>Server Name Problem</h1>
<p>Finally the export phase can be completed. Next problem is the transfer phase, which simply moves the exported files from the server assigned the task of performing the content deployment job to the destination server. In the path specification the location of the Central Administration site on the destination server is specified along with the destination web application and site collection.</p>
<p>The source server tries to export the file directly to the destination server handling content deployment jobs, which might or might not be the same server that’s running the Central Administration site. It does so by resolving the FQDN (Fully Qualified Domain Name) of the server, which might very likely be a problem to you.</p>
<p>If you deploy content between servers in separate network segments this won’t work out of the box, e.g. the source server can probably not find your destination server by the name “<em>my_dest_server.my_domain”</em>, which is only known within the immediate local AD domain of that server.</p>
<p>There’s no reason to think too deeply about these names – just try to do a content deployment and if it fails during the transport phase it’ll report “The remote upload Web request failed” along with the name it’s trying to resolve. A similar event log entry is also created:</p>
<p><span style="font-size:9pt;color:red;"><br />
Event Type: Error<br />
Event Source: Windows SharePoint Services 3<br />
Event Category: Timer<br />
Event ID: 6398<br />
Date: 6/12/2007<br />
Time: 9:48:07 PM<br />
User: N/A<br />
Computer:<br />
Description:<br />
</span><br />
<span style="font-size:9pt;color:red;">The Execute method of job definition Microsoft.SharePoint.Publishing.Administration.ContentDeploymentJobDefinition (ID 2f94ff2b-2aa1-498b-96ba-649c2e75ada7) threw an exception. More information is included below.<br />
</span></p>
<p><span style="font-size:9pt;color:red;">The remote name could not be resolved: ‘<em>servername</em>.dev.local’<br />
</span></p>
<p><span style="font-size:9pt;color:red;">For more information, see Help and Support Center at <a href="http://go.microsoft.com/fwlink/events.asp"><span style="color:#909d73;">http://go.microsoft.com/fwlink/events.asp</span></a>.<br />
</span></p>
<p>The fix is simple:</p>
<ol>
<li>Open your host file, usually located at c:\windows\system32\drivers\etc\hosts</li>
<li>Add a new line (don’t delete existing lines): “qqq.xxx.yyy.zzz <em>servername.dev.local</em>“. Be sure to use the correct ip address and name for your destination server. Remember that it should be an ip address that works from the source server (in some cases internal other external ip). You can probably get away with specifying the same ip address you used for the Central Administration site in that <em>path</em> definition – if you used a dns name then just ping the dns and grab the ip address.</li>
<li>Save the file</li>
<li>Retry your content deployment. No need to restart any services the fix is immediate.</li>
</ol>
<h1>Feature problems – part II</h1>
<p>We’re now in the import phase and almost through. During the import SharePoint will check whether all the activated features at the source site collection (and sub sites) are also available at the destination site collection.</p>
<p>If not you’ll get an informative error, similar to: “<span style="color:red;">Content deployment job ‘Remote import job for job with sourceID = 71bb6ada-762c-4e78-8bc3-2a105bbe5988′ failed.The exception thrown was ‘Microsoft.SharePoint.SPException’ : ‘Could not find Feature <em>xxxxxx</em>.’</span></p>
<p>The solution is obvious – install the same solutions/features at the destination web application as on the source.</p>
<h1>Specified Name is already in use</h1>
<p>If you get an error similar to “<span style="color:red;">Content deployment job ‘Remote import job for job with sourceID = 71bb6ada-762c-4e78-8bc3-2a105bbe5988′ failed.The exception thrown was ‘Microsoft.SharePoint.SPException’ : ‘The specified name is already in use. A list, survey, discussion board, or document library cannot have the same name as another list, survey, discussion board, or document library in this Web site. Use your browser’s Back button, and type a new name.’</span>“</p>
<p>You forgot to read the manual (ok, blogs) that specifies that the destination site collection should be a brand new blank site collection – in my case I tried to export to a newly created publishing site collection. <span style="color:red;"><br />
</span></p>
<h1>The Small Print</h1>
<p>Finally your content deployment ought to be complete <span style="font-family:Wingdings;"><img class="wp-smiley" src="http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif" alt="-)" /> </span></p>
<p>If your site looks a bit strange it’s probably because the master page settings wasn’t copied, so you’ll have to assign the correct master page through the site settings. Might also be the case for the welcome page, though I haven’t confirmed it.</p>
<p>During the export every file of your site will be copied to the deployment package so if any files have gone missing you’ll get appropriate warnings during the export, but it’ll still complete.</p>
<p>This is actually a great way to detect if any aspx files have been deleted by accident, e.g. an AllItems.aspx page for a custom list might have gone missing if somebody changed the list definition (probably deployed within a feature).</p>
<p>Phew! At least it works for me now…</p>
<h2><span style="color:#ff0000;">(Updated)</span> Other bugs</h2>
<p>This is a small list of other bugs I’ve heard/read about</p>
<p>1. (Thanks Harry!) The Cab-files are not always deleted and remain in the folder C:\WINDOWS\Temp\ContentDeployment. Regardless of the content deployment setting of the number of jobs to keep, they will not be deleted. Roll your own workaround and delete the files. You could schedule a job to delete everything older than 1 day (as I’m sure your job can complete in less time than that)</p>
<p>And of course: Move the directory location to a non-system drive</p>
<p>2. (Thanks Harry!) Specific sites within the site collection: I select only the language-variations but not the root. After Test Job or Run Now the root has been always added to the Scope (Fix 937208 apparently solves the problem)</p>
<p>3. Some characters are mangled after deployment, specifically “nbsp;” in html fields (probably a lot of others too). Update: This has been fixed with hotfix 938536 (private hotfix for now &#8211; sorry) <img class="wp-smiley" src="http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif" alt="-)" /></p>
<p>4. Missing disk space on destination server will be reported (on the source server) as<br />
<span style="font-size:9pt;color:red;">Failed to read package file. at Microsoft.SharePoint.Deployment.ImportDataFileManager.Uncompress(SPRequest request) at Microsoft.SharePoint.Deployment.SPImport.Run() *** Inner exception: Failure writing to target file at Microsoft.SharePoint.Library.SPRequest.ExtractFilesFromCabinet(String bstrTempDirectory, String bstrCabFileLocation) at Microsoft.SharePoint.Deployment.ImportDataFileManager.&lt;&gt;c__DisplayClass2.&lt;Uncompress&gt;b__0() at Microsoft.SharePoint.SPSecurity.CodeToRunElevatedWrapper(Object state) at Microsoft.SharePoint.SPSecurity.&lt;&gt;c__DisplayClass4.&lt;RunWithElevatedPrivileges&gt;b__2() at Microsoft.SharePoint.Utilities.SecurityContext.RunAsProcess(CodeToRunElevated secureCode) at Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(WaitCallback secureCode, Object param) at Microsoft.SharePoint.SPSecurity.RunWithElevatedPrivileges(CodeToRunElevated secureCode) at Microsoft.SharePoint.Deployment.ImportDataFileManager.Uncompress(SPRequest request)</span></p>
<p>5. If you choose to copy “all” security information between servers not in the same domain you might get the following error (copying role definitions only works fine)<span style="font-size:9pt;color:red;"><br />
A duplicate name “62c4fcbb-7ff7-4cc3-842e-17476b2e6219″ was found. at Microsoft.SharePoint.SPFieldCollection.AddFieldAsXmlInternal(String schemaXml, Boolean addToDefaultView, SPAddFieldOptions op) at Microsoft.SharePoint.Deployment.ListSerializer.CreateOrUpdateField(SPList list, String fieldName, XmlNode fieldNode) at Microsoft.SharePoint.Deployment.ListSerializer.UpdateListFields(SPList list, Dictionary`2 listMetaData) at Microsoft.SharePoint.Deployment.ListSerializer.SetObjectData(Object obj, SerializationInfo info, StreamingContext context, ISurrogateSelector selector) at Microsoft.SharePoint.Deployment.XmlFormatter.ParseObject(Type objectType, Boolean isChildObject) at Microsoft.SharePoint.Deployment.XmlFormatter.DeserializeObject(Type objectType, Boolean isChildObject, DeploymentObject envelope) at Microsoft.SharePoint.Deployment.XmlFormatter.Deserialize(Stream serializationStream) at Microsoft.SharePoint.Deployment.ObjectSerializer.Deserialize(Stream serializationStream) at Microsoft.SharePoint.Deployment.ImportObjectManager.ProcessObject(XmlReader xmlReader) at Microsoft.SharePoint.Deployment.SPImport.DeserializeObjects() at Microsoft.SharePoint.Deployment.SPImport.Run()<br />
</span></p>
<p>On hotfixes: Please note that hotfixes are cumulative and later numbers super seeds earlier ones &#8211; so the game is to get the highest number of all <img src='http://s1.wp.com/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' />  </p>
<h2><span style="color:#ff0000;">(Updated)</span> Conclusion (sort of)</h2>
<p>Some of you have asked (in the comments) whether or not it all worked in the end. It actually did work! <img class="wp-smiley" src="http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif" alt="-)" /> All of the above steps where enough to solve our immediate problems with the content deployment between our three environments.</p>
<p>Great! So do we use it? No.</p>
<p>We really really wanted to use this feature and all looked so well after our the latest hotfix deployment that we planned to use it for the existing publishing site as well as for a some additional upcoming site collections we’re developing.</p>
<p>One particular annoying feature (sorry for the pun) is breaking the content deployment which I have yet to find a solution for. The new sites are based on custom site definitions and a number of features that creates custom content types and site columns from a number of xml files. Some of these site columns are lookup columns that which cannot be created with xml files the same way as every other site column, because they need to refer to an existing list by list id (in the xml file) but the list will be assigned a dynamic id by the system when it’s created (by another feature that the site columns is dependent on).</p>
<p>To get around that problem a feature activation handled is executed that creates the lookup site columns using custom code that find the dynamic list id from the name. That code is roughly based on code found on codeplex (<a title="SP2007LookupFields" href="http://www.codeplex.com/SP2007LookupFields"><span style="color:#909d73;">here</span></a>). Some minor differences: I fixed some bugs with internal/display name mixup, reactivation problems and a missing “webid” (had to be dynamic as well) in the constructed field. The missing “webid” did cause content deployment to fail immediatly. For some reason I have yet to track down it now fails if the content type using one of the lookup site columns is in use, i.e. a list item of that type exists anywhere in the site collection. For lookup site columns created through the web interface there are no problems. Bummer.</p>
<p>The choice we’re facing (barring that I manage to solve the problem before long) is</p>
<p>1. Either: We can define the content type through xml files</p>
<p>2. Or: we can use content deployment and create content types manually through the web interface &#8211; they will be copied as part of the content deployment)</p>
<p>We chose the first option as content deployment at the current level of maturity seems too unstable. Furthermore we also decided to use only one strategy and therefore not use the content deployment for the first site collection that this article originally targetted (one where all content types where created through the web interface).  </p>
<p>How do we do it now? We use “stsadm -o backup/restore” to deploy new versions of the site. It’s essentially a database backup with all the benefits and drawbacks of such. It’s very stable. Specifically history of all items are maintained, you get a messed up user database where you’ll (eventually) find users from all environments, you need to explicitly set new ownership (to a valid user that can be found in the relevant environments AD), you get the luxury of copied security permissions sets and groups (which I might still build a tool to import/export).</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/sharepointhelps.wordpress.com/64/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/sharepointhelps.wordpress.com/64/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointhelps.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointhelps.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointhelps.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointhelps.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointhelps.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointhelps.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointhelps.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointhelps.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointhelps.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointhelps.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointhelps.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointhelps.wordpress.com/64/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointhelps.wordpress.com/64/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointhelps.wordpress.com/64/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=64&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointhelps.wordpress.com/2008/08/06/the-long-path-to-content-deployment/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/d80eb71b2c8d6f45fa035457c1d5e8fc?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">vamsankar</media:title>
		</media:content>

		<media:content url="http://soerennielsen.files.wordpress.com/2007/06/061907-2220-thelongpath1.png" medium="image" />

		<media:content url="http://soerennielsen.files.wordpress.com/2007/06/061907-2220-thelongpath2.png" medium="image" />

		<media:content url="http://s.wordpress.com/wp-includes/images/smilies/icon_wink.gif" medium="image">
			<media:title type="html">;-)</media:title>
		</media:content>

		<media:content url="http://soerennielsen.files.wordpress.com/2007/06/061907-2220-thelongpath3.png" medium="image" />

		<media:content url="http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif" medium="image">
			<media:title type="html">-)</media:title>
		</media:content>

		<media:content url="http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif" medium="image">
			<media:title type="html">-)</media:title>
		</media:content>

		<media:content url="http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif" medium="image">
			<media:title type="html">-)</media:title>
		</media:content>

		<media:content url="http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif" medium="image">
			<media:title type="html">-)</media:title>
		</media:content>
	</item>
		<item>
		<title>Programmatically Update List Content in SharePoint</title>
		<link>http://sharepointhelps.wordpress.com/2008/08/05/programmatically-update-list-content-in-sharepoint/</link>
		<comments>http://sharepointhelps.wordpress.com/2008/08/05/programmatically-update-list-content-in-sharepoint/#comments</comments>
		<pubDate>Tue, 05 Aug 2008 10:23:04 +0000</pubDate>
		<dc:creator>vamsankar</dc:creator>
				<category><![CDATA[Microsoft Office Sharepoint Server]]></category>
		<category><![CDATA[Windows Sharepoint Services]]></category>

		<guid isPermaLink="false">http://sharepointhelps.wordpress.com/?p=61</guid>
		<description><![CDATA[The Below is the Sample Code to update the Sharepoint list content programmatically by using SharePoint Object Model. SPSite Site = new SPSite(&#8220;http://localhost:21000&#8243;); SPWeb Web = Site.OpenWeb(); SPList List = Web.Lists["Address Book"]; SPListItem ListItem = List.GetItemById(0); string FullName = string.Empty; FullName = ListItem["FirstName"].ToString() + ListItem["LastName"].ToString(); SPListItem["FullName"] = FullName; ListItem.Update();<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=61&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>The Below is the Sample Code to update the Sharepoint list content programmatically by using SharePoint Object Model.</p>
<p>SPSite Site = new SPSite(&#8220;http://localhost:21000&#8243;);<br />
SPWeb Web = Site.OpenWeb();<br />
SPList List = Web.Lists["Address Book"];<br />
SPListItem ListItem = List.GetItemById(0);</p>
<p>string FullName = string.Empty;</p>
<p>FullName = ListItem["FirstName"].ToString() + ListItem["LastName"].ToString();<br />
SPListItem["FullName"] = FullName;<br />
ListItem.Update();</p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/sharepointhelps.wordpress.com/61/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/sharepointhelps.wordpress.com/61/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointhelps.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointhelps.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointhelps.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointhelps.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointhelps.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointhelps.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointhelps.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointhelps.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointhelps.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointhelps.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointhelps.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointhelps.wordpress.com/61/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointhelps.wordpress.com/61/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointhelps.wordpress.com/61/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=61&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointhelps.wordpress.com/2008/08/05/programmatically-update-list-content-in-sharepoint/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/d80eb71b2c8d6f45fa035457c1d5e8fc?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">vamsankar</media:title>
		</media:content>
	</item>
		<item>
		<title>CAML Query Builder V2</title>
		<link>http://sharepointhelps.wordpress.com/2008/08/05/caml-query-builder-v2/</link>
		<comments>http://sharepointhelps.wordpress.com/2008/08/05/caml-query-builder-v2/#comments</comments>
		<pubDate>Tue, 05 Aug 2008 06:48:13 +0000</pubDate>
		<dc:creator>vamsankar</dc:creator>
				<category><![CDATA[Microsoft Office Sharepoint Server]]></category>
		<category><![CDATA[Windows Sharepoint Services]]></category>

		<guid isPermaLink="false">http://sharepointhelps.wordpress.com/?p=59</guid>
		<description><![CDATA[Querying Data with the CAML Query Builder V2 It has been a couple of months now since we have released the first version of the CAML Query Builder. Thanks a lot for the very positive feedback we have received from you all. Do remember that this is side-project of our CAML girl and not a [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=59&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<div class="ExternalClass93698F75E6B1456FA550157881D0D7A1">
<p><strong><span style="text-decoration:underline;">Querying Data with the CAML Query Builder V2</span></strong></p>
<p>It has been a couple of months now since we have released the first version of the CAML Query Builder. Thanks a lot for the very positive feedback we have received from you all. Do remember that this is side-project of our CAML girl and not a fully commercial product. So we do our best to get everything working and support you with any questions but sometimes you have to be patient. Sorry for that.</p>
<p>Today, you can download version 2 giving you the following additional features on top of what you find in version 1. You can learn about the v1 features by reading my first posting on the CAML Query Builder tool over <a href="http://blog.u2u.info/DottextWeb/patrick/archive/2005/03/28/1617.aspx">here</a>.</p>
<p><strong><em>So, what is new in v2?</em></strong></p>
<ul>
<li>You can now choose whether you work in <strong>object model or in Web services mode</strong>. It means that you now can use the app on the SharePoint machine itself and on a client accessing the SharePoint content via the Web services.</li>
<li>When working with the object model, you can only query for content. If you opt for Web services mode, you can query but also now <strong>update content in a SharePoint list using CAML</strong>.</li>
<li>You now also have the possibility to make <strong>use of parameters</strong> and give these parameters a value at runtime when using the CAML Server Helper to execute the saved CAML query string.</li>
</ul>
<p>The new version is downloadable using the following link: <a href="http://www.u2u.info/SharePoint/U2U%20Community%20Tools/CamlCreatorV2.zip">http://www.u2u.info/SharePoint/U2U%20Community%20Tools/CamlCreatorV2.zip</a>.</p>
<p><span style="color:#ff0000;">Update: Always go the <strong><a href="http://www.u2u.info/SharePoint/U2U%20Community%20Tools/Forms/AllItems.aspx">library itself</a></strong> to download the latest version available.</span></p>
<p>And don&#8217;t forget that you find on <a href="http://www.u2u.info/SharePoint">http://www.u2u.info/SharePoint</a> some other goodies to play with.</p>
<p>Now before you start looking at the tutor, read my <a href="http://blog.u2u.info/DottextWeb/patrick/archive/2005/03/28/1617.aspx">previous posting</a> and the article on using the <a href="http://blog.u2u.info/DottextWeb/patrick/archive/2005/03/28/1617.aspx">SmartPart</a>.</p>
<p>Just like before, I will illustrate the use of the CAML Query Builder and the new features using a small example. I will make use of the same SharePoint list as before showing the AdventureWorks products.</p>
<p><img src="http://www.u2u.info/BlogImages/caml01.jpg" alt="" /> </p>
<p>U2UCamlCreator.exe starts the query builder application. You can set the credentials and also now choose the mode you want to work in.</p>
<p><img src="http://www.u2u.info/BlogImages/camlv201.PNG" alt="" /></p>
<p><strong><span style="text-decoration:underline;">Getting only the fields you need</span></strong></p>
<p>V1 of the CAML Query Builder retrieved always all of the fields from the list. This version here allows you to select the fields you want to get returned from the SharePoint site. Just right-click on the list you want to work with in the treeview. <em>Note that this only works now for the Web services mode.</em></p>
<p><img src="http://www.u2u.info/BlogImages/camlv202.PNG" alt="" /></p>
<p>Using the View Fields tab and the listboxes you can then define the fields you want to work with. Clicking on the Query tab allows you to define the query then as with the V1 version.</p>
<p><img src="http://www.u2u.info/BlogImages/camlv203.PNG" alt="" /></p>
<p>And of course, you can test it again.</p>
<p><img src="http://www.u2u.info/BlogImages/camlv204.PNG" alt="" /></p>
<p> </p>
<p><strong><span style="text-decoration:underline;">Dynamic Parameters</span></strong></p>
<p>If you want to have the filtering value dynamic, you can now insert in the value field the name of a parameter enclosed between []. If you follow my steps, you can click now in the treeview displaying the results of your actions on the Model node.</p>
<p><img src="http://www.u2u.info/BlogImages/camlv206.PNG" alt="" /></p>
<p><img src="http://www.u2u.info/BlogImages/camlv205.PNG" alt="" /></p>
<p>The name of the parameter is free, just use the brackets so that the CAML girl knows that you want to go dynamic.</p>
<p>In the test pane, you can then give a value to this parameter. Move to the second tab and click parameters. The Get Parameters button can be used to fill up the datagrid with your parameters.</p>
<p><img src="http://www.u2u.info/BlogImages/camlv207.PNG" alt="" /></p>
<p>And of course, you can test again your query.</p>
<p><strong><span style="text-decoration:underline;">Executing the Query in your Code</span></strong></p>
<p>The CAML builder allows you to store the query as a file. Just use the File | Save File menu item. Once it is saved, we can use the server component of the CAML builder to have this query executed within our code. Just like the <a href="http://blog.u2u.info/DottextWeb/patrick/archive/2005/03/28/1617.aspx">previous tutor</a>, I have a small ASP.NET user control that I am going to host in the smartpart. Except now I have a text box where we can enter a search string.</p>
<p><img src="http://www.u2u.info/BlogImages/camlv208.PNG" alt="" /></p>
<p>Follow the steps discussed in the previous tutor to set the reference and then create an object of the CAML Helper.<br />
You need a reference to the following assemblies:</p>
<ul>
<li>U2U.SharePoint.CAML.dll</li>
<li>U2U.SharePoint.CAML.Server.dll</li>
</ul>
<p>Since we are having one parameter, you need to first create an array of CAMLParameter objects and add to it one CAMLParameter object.<br />
Just like before, the ExecuteQuery method returns you a ADO.NET DataTable you can immediately bind to your DataGrid.</p>
<p><span style="font-family:Courier;">U2U.SharePoint.CAML.Server.CAMLHelper helper =<br />
     new U2U.SharePoint.CAML.Server.CAMLHelper<br />
       (Server.MapPath(&#8220;~/UserControls/products_v2.caml&#8221;));<br />
U2U.SharePoint.CAML.CamlParameter[] pars = new U2U.SharePoint.CAML.CamlParameter[1];<br />
pars[0] = new U2U.SharePoint.CAML.CamlParameter(&#8220;Model&#8221;,TextBox1.Text);<br />
DataTable dt = helper.ExecuteQuery(pars);<br />
DataGrid1.DataSource = dt;<br />
DataGrid1.DataBind();</span></p>
<p>The result can be displayed in the Web part:</p>
<p><img src="http://www.u2u.info/BlogImages/camlv209.PNG" alt="" /></p>
<p> </p>
<p>You can also use the CAML Query Builder now to construct your query string to do update/new/delete operations via CAML. I will give a sample and some steps to follow hopefully later this week. It is getting late here in Oslo and tomorrow is again working day <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> . 2 days in Oslo and then going all the way from Northern Europe to South-Africa for 2 more days on Portals.</p>
<p>Have fun with it! You can send questions, feedback, bug reports either to me (<a href="mailto:patrick@u2u.be">patrick@u2u.be</a>) or directly to our CAML girl (<a href="mailto:karine@u2u.be">karine@u2u.be</a>).</div>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/sharepointhelps.wordpress.com/59/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/sharepointhelps.wordpress.com/59/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointhelps.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointhelps.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointhelps.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointhelps.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointhelps.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointhelps.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointhelps.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointhelps.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointhelps.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointhelps.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointhelps.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointhelps.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointhelps.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointhelps.wordpress.com/59/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=59&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointhelps.wordpress.com/2008/08/05/caml-query-builder-v2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/d80eb71b2c8d6f45fa035457c1d5e8fc?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">vamsankar</media:title>
		</media:content>

		<media:content url="http://www.u2u.info/BlogImages/caml01.jpg" medium="image" />

		<media:content url="http://www.u2u.info/BlogImages/camlv201.PNG" medium="image" />

		<media:content url="http://www.u2u.info/BlogImages/camlv202.PNG" medium="image" />

		<media:content url="http://www.u2u.info/BlogImages/camlv203.PNG" medium="image" />

		<media:content url="http://www.u2u.info/BlogImages/camlv204.PNG" medium="image" />

		<media:content url="http://www.u2u.info/BlogImages/camlv206.PNG" medium="image" />

		<media:content url="http://www.u2u.info/BlogImages/camlv205.PNG" medium="image" />

		<media:content url="http://www.u2u.info/BlogImages/camlv207.PNG" medium="image" />

		<media:content url="http://www.u2u.info/BlogImages/camlv208.PNG" medium="image" />

		<media:content url="http://www.u2u.info/BlogImages/camlv209.PNG" medium="image" />
	</item>
		<item>
		<title>The security validation for this page is invalid. Click Back in your Web</title>
		<link>http://sharepointhelps.wordpress.com/2008/08/05/the-security-validation-for-this-page-is-invalid-click-back-in-your-web/</link>
		<comments>http://sharepointhelps.wordpress.com/2008/08/05/the-security-validation-for-this-page-is-invalid-click-back-in-your-web/#comments</comments>
		<pubDate>Tue, 05 Aug 2008 05:24:35 +0000</pubDate>
		<dc:creator>vamsankar</dc:creator>
				<category><![CDATA[Microsoft Office Sharepoint Server]]></category>
		<category><![CDATA[Windows Sharepoint Services]]></category>

		<guid isPermaLink="false">http://sharepointhelps.wordpress.com/?p=54</guid>
		<description><![CDATA[If you are getting the following error, while renaming the page title using publishingpage object &#8220;The security validation for this page is invalid. Click Back in your Webbrowser, refresh the page, and try your operation again.&#8221; Code Snippet: PublishingWeb publishingweb = PublishingWeb.GetPublishingWeb(newUri(&#8220;http://severname/sitename/&#8220;)); PublishingPage pp =publishingweb.GetPublishingPages()["Pages/TestArticle.aspx"]; pp.Title = e.Node.Text; pp.Update(); You should check for this : [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=54&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><span style="font-size:x-small;"><span style="font-size:85%;font-family:arial;">If you are getting the following error, while renaming the page title using publishingpage object<br />
&#8220;<span style="color:#ff0000;">The security validation for this page is invalid. Click Back in your Webbrowser, refresh the page, and try your operation again</span>.&#8221;<br />
</span><br />
<span style="font-size:85%;font-family:arial;"><strong>Code Snippet:</strong></span><br />
<span style="font-size:85%;font-family:arial;"><strong></strong></span><br />
<span style="font-size:85%;font-family:arial;"><strong>PublishingWeb publishingweb = PublishingWeb.GetPublishingWeb(newUri(&#8220;</strong></span></span><a href="http://yourportal/Plans/"><span style="font-size:85%;font-family:arial;"><strong><span style="font-size:x-small;color:#666699;">http://severname/sitename/</span></strong></span></a><span style="font-size:x-small;"><span style="font-size:85%;font-family:arial;"><strong>&#8220;));<br />
PublishingPage pp =publishingweb.GetPublishingPages()["Pages/TestArticle.aspx"];</strong></span><br />
<span style="font-size:85%;font-family:arial;"><strong>pp.Title = e.Node.Text;</strong></span><br />
<span style="font-size:85%;font-family:arial;"><strong>pp.Update();</strong></span><br />
</span></p>
<p><span style="font-size:85%;font-family:arial;"><span style="font-size:x-small;">You should check for this :</span></span></p>
<p><span style="font-size:85%;font-family:arial;"><span style="font-size:x-small;">Navigate thru the followwing and turn the security validation Off</span></span></p>
<p><span style="font-size:85%;font-family:arial;"><span style="color:#3333ff;"><span style="font-size:x-small;">Central Administration&#8212;&gt;application management&#8212;-&gt;Web application general settings<span style="color:#000000;"> under SharePoint Web Application Management Tab </span>&#8211;&gt;  Then select your site, and set &#8220;turn security validation off&#8221; then click OK Button.</span></span></span></p>
<br /><img alt="" border="0" src="http://feeds.wordpress.com/1.0/categories/sharepointhelps.wordpress.com/54/" /> <img alt="" border="0" src="http://feeds.wordpress.com/1.0/tags/sharepointhelps.wordpress.com/54/" /> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/sharepointhelps.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/sharepointhelps.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/sharepointhelps.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/sharepointhelps.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/sharepointhelps.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/sharepointhelps.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/sharepointhelps.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/sharepointhelps.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/sharepointhelps.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/sharepointhelps.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/sharepointhelps.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/sharepointhelps.wordpress.com/54/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/sharepointhelps.wordpress.com/54/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/sharepointhelps.wordpress.com/54/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=sharepointhelps.wordpress.com&amp;blog=4171137&amp;post=54&amp;subd=sharepointhelps&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://sharepointhelps.wordpress.com/2008/08/05/the-security-validation-for-this-page-is-invalid-click-back-in-your-web/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/d80eb71b2c8d6f45fa035457c1d5e8fc?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">vamsankar</media:title>
		</media:content>
	</item>
	</channel>
</rss>
