Sharepoint : Div tag with ExternalClass

December 16, 2014

Every time I insert enhanced rich text in a field in SharePoint and
save it, SharePoint inserts DIV tags with an external class reference
around my content.

Why does it do this? Where is this class? What does it specify?

have multilined text field. When it is empty it is rendering in the list view as below. Can anyone tell me why and how to fix it?

– See more at:

Solution :

You can use Regex.Replace(currentItem[“Your Field Name”].ToString(), “”, string.Empty); Basically this will replace your div tag with empty string so you will get your plain text

In Jquery use regex like this – stringvalue.Replace(“”, “”);


Sharepoint 2010 and 2013 : managed metadata columns

February 26, 2013

If the requirement is like you want to manage all your default values for columns from central place then create Managed metadata ..

SharePoint 2013 is out

July 18, 2012


Please check the link below indicating the new offerings from Microsoft.  Fantastic feature in SharePoint 2013.





Please check the link below indicating the new offerings from Microsoft.  Fantastic feature in SharePoint 2013.


Sharepoint 2010 workflows

December 24, 2011

types of workflows:


2.Content Type (Reusable )

3. Sites

Out of box workflows:


2.Collect feedback

3.Collect signature

4. Three state

5. Disposition

6,Translation Mngt

Defining sharepoint custom sequential workflow thru code:


When to go for Visual Studio workflows in place of sharepoint designers:


When should I use Visual Studio for Workflow?

As I mentioned earlier SharePoint Designer (SPD) is a great platform for developing basic workflows, however it has several limitations and in some cases these can mean that you have to look at Visual Studio as the solution for your workflow design.

In my experience the limitations of SPD are as follows:

  1. Workflows are bound to a specific list/site
     In SPD any workflow you create can only exist on the list (and in the site) that you created the workflow on.  You cannot design a workflow and then move it to another site.
  2. No code support
    You cannot write custom code within the SPD workflow tools.  You can write custom activities to include in SPD, but you would need to do that in Visual Studio anyway.
  3. No WSS Solution Package (WSP) support
    Your workflow will be deployed to the site via SPD and there is no support for packaging these as WSP files, which provide a more maintainable and upgradeable method of deploying customisations to SharePoint.
  4. No support for State Machine workflows
    You can only build Sequential workflows with SPD, there is no support for State Machine Workflows.

Sharepoint : Default approval workflows

December 24, 2011

Default approval workflows

Microsoft SharePoint Server 2010 includes several approval workflows that you can begin using right away to manage human workflows in your organization. Each workflow can be added to a list, library, or content type and then used by your business users to manage the items or documents in the associated lists or libraries.

You can use the workflows to run document approvals, collect feedback, collect signatures, manage publishing of assets, manage dispositions, and create three-state approvals. When you associate and initiate the workflow, you can change the basic behaviors of the workflow, like who approves it, how the tasks are assigned, duration, due dates, workflow messages, and so on. For most of the workflows, you can also customize them in SharePoint Designer 2010.

Each workflow is described below, including the main differences between the workflows, and whether they’re supported for customization in SharePoint Designer 2010.

Workflow Description In SharePoint Designer
Approval The Approval workflow routes a document or item to a group of people for approval.

It supports staged approvals whereby the first set of approvers can review and approve, then the next set of approvers can review and approve, and so on. Each stage of approvers can do review in serial order (one at a time), parallel order (all at once), and normal serial or parallel task assignments that were supported in SharePoint Server 2007.

The duration and due dates of the task can be specified in days, weeks, and months, as well as a final due date for all of the tasks in the workflow. You can individuals to the CC (carbon copy) field. The workflow can be set up to end when the first approver rejects it. It can end if the document being review is changed. And, the workflow can enable content approval, if you like.

The tasks and emails in the workflow request content approval, so the task form includes buttons for Approve, Reject, Request Change, and Reassign. For approvers, comments support a consolidated comment that shows the entire list of previous approvers’ comments. Approval workflows can also be used to set content approval status at the end.

The Approval workflow is by default associated with the Document content type so it is available to document libraries.

NOTE: This workflow is only available in SharePoint Server 2010.

Collect Feedback The Collect Feedback workflow is very similar to the Approval workflow. It routes items or documents to a group of people, but in this case, the workflow is designed to get feedback from the approvers. The feedback is compiled and sent back to the person who initiated the workflow.

Like the Approval workflow, this workflow supports staged approvals and lets you specify duration and due dates in days, weeks, and months, as well as the final due date. The workflow can also be set up to end if the document is changed, and you can add individuals to the CC (carbon copy) field.

Unlike the Approval workflow, there is no option to end the workflow on first rejection since that doesn’t apply here, and there is no option to enable content approval.

Since the tasks and emails in the workflow request content approval, the task form includes buttons for Send Feedback, Request Change, and Reassign.

The Collect Feedback workflow is associated with the Document content type so it is available in document libraries.

NOTE: This workflow is only available in SharePoint Server 2010.

Collect Signatures The Collect Signatures workflow routes documents created in a Microsoft application to a group of people to collect their digital signatures.

You can add signers in serial or parallel order, and you can add them in stages. You can also add individuals to the CC (carbon copy) field. There are no other fields or behaviors for this workflow (unlike the Approval and Collect Feedback workflows).

When the signers of the workflow receive the task, they can sign it from the Task list in SharePoint or from within the host document, such as Microsoft Word, Excel, and PowerPoint.

The task form includes buttons for Sign or Reassign the task only. The signing mechanism uses the Microsoft Office Signature Line control. The signature image can be provided by the user or applied automatically using logic in the form (specifically, rule and action in the InfoPath form).

The Collect Signatures workflow is associated with the Document content type so it is available in document libraries However, the workflow will only appear in the library if that document contains one or more Microsoft Office Signature Lines.

NOTE: This workflow is only available in SharePoint Server 2010.

Publishing The Publishing workflow routes content for approval in the same the Approval workflow does this except that it’s designed for Enterprise Content Management sites with publishing features enabled.

Another difference is in the workflow forms. The association and initiation forms hide the option to add approvers, end workflow on first rejection, end workflow if document changes, and enable content approval.

NOTE: The Publishing workflow is only available in SharePoint Server 2010 where the Publishing feature is enabled.

Three-state The Three-state workflow tracks the status of an issue or item through three states and two transitions between the states, which help track high volume issues.

The workflow is designed to work with the Issue Tracking list template but can be used with any list that has a Choice column with three or more values that serve as the state of the workflow.

Participants in the workflow may be working with the list directly or outside projects related to the list. The workflow updates the status of the list and creates a new task for the next participant, and this process continues.

Workflow participants can change the complete their task or change the status of the workflow item.

NOTE: This workflow is available in both SharePoint Foundation 2010 and SharePoint Server 2010.

Disposition Approval The Disposition Approval workflow tracks content that has expired or is out-of-date and needs to be evaluated or deleted.

This workflow is especially useful on a Records Center site or a site that supports records management document retention policies. The workflow can be configured to start automatically when documents or items expire or started manually by participants.

The workflow uses Disposition Approval workflow tasks for specific documents and items in the tasks list rather than assigning them to specific participants. Only those who have permissions to this tasks list can complete the task by approving or rejecting items for deletion.

The workflow also includes bulk task completion so that individuals can process large numbers of items for deletion in one step. This is commonly needed because of the high volume of tasks generated by the workflow.

NOTE: This workflow is only available in SharePoint Server 2010.

Sharepoint Notes

March 8, 2010

What is a 3 state workflow?

2.Difference between Features, Feature Deffinition and Solutions
Using Features and Solutions will help customize sites and site templates.

Features: It helps sites to reuse functionality from one site to other sites without requiring to copy and paste XML. It is also an instance of Feature Definition.

Solutions: It helps to package Features in a cabinet (.cab) file along with meta data.

Feature Definition: It hides feature manifest contained in a feature directory and are installed at farm level.

3.Key difference between Sharepoint 2007 and 2010

major difference which is everything will and has to be 64 bit:

SharePoint Server 2010 will be 64-bit only.
SharePoint Server 2010 will require 64-bit Windows Server 2008 or 64-bit Windows Server 2008 R2.
SharePoint Server 2010 will require 64-bit SQL Server 2008 or 64-bit SQL Server 2005.

What is Microsoft Windows SharePoint Services? How is it related to Microsoft Office SharePoint Server 2007?
Windows SharePoint Services is the solution that enables you to create Web sites for information sharing and document collaboration. Windows SharePoint Services — a key piece of the information worker infrastructure delivered in Microsoft Windows Server 2003 — provides additional functionality to the Microsoft Office system and other desktop applications, and it serves as a platform for application development.

Office SharePoint Server 2007 builds on top of Windows SharePoint Services 3.0 to provide additional capabilities including collaboration, portal, search, enterprise content management, business process and forms, and business intelligence.

[edit]What is Microsoft SharePoint Portal Server?
SharePoint Portal Server is a portal server that connects people, teams, and knowledge across business processes. SharePoint Portal Server integrates information from various systems into one secure solution through single sign-on and enterprise application integration capabilities. It provides flexible deployment and management tools, and facilitates end-to-end collaboration through data aggregation, organization, and searching. SharePoint Portal Server also enables users to quickly find relevant information through customization and personalization of portal content and layout as well as through audience targeting.

[edit]What is Microsoft Windows Services?
Microsoft Windows Services is the engine that allows administrators to create Web sites for information sharing and document collaboration. Windows SharePoint Services provides additional functionality to the Microsoft Office System and other desktop applications, as well as serving as a plat form for application development. SharePoint sites provide communities for team collaboration, enabling users to work together on documents, tasks, and projects. The environment for easy and flexible deployment, administration, and application development.

[edit]What is the relationship between Microsoft SharePoint Portal Server and Microsoft Windows Services?
Microsoft SharePoint Products and Technologies (including SharePoint Portal Server and Windows SharePoint Services) deliver highly scalable collaboration solutions with flexible deployment and management tools. Windows SharePoint Services provides sites for team collaboration, while Share Point Portal Server connects these sites, people, and business processes—facilitating knowledge sharing and smart organizations. SharePoint Portal Server also extends the capabilities of Windows SharePoint Services by providing organizational and management tools for SharePoint sites, and by enabling teams to publish information to the entire organization.

[edit]Who is Office SharePoint Server 2007 designed for?
Office SharePoint Server 2007 can be used by information workers, IT administrators, and application developers. is designed

[edit]What are the main benefits of Office SharePoint Server 2007?
Office SharePoint Server 2007 provides a single integrated platform to manage intranet, extranet, and Internet applications across the enterprise.

Business users gain greater control over the storage, security, distribution, and management of their electronic content, with tools that are easy to use and tightly integrated into familiar, everyday applications.
Organizations can accelerate shared business processes with customers and partners across organizational boundaries using InfoPath Forms Services–driven solutions.
Information workers can find information and people efficiently and easily through the facilitated information-sharing functionality and simplified content publishing. In addition, access to back-end data is achieved easily through a browser, and views into this data can be personalized.
Administrators have powerful tools at their fingertips that ease deployment, management, and system administration, so they can spend more time on strategic tasks.
Developers have a rich platform to build a new class of applications, called Office Business Applications, that combine powerful developer functionality with the flexibility and ease of deployment of Office SharePoint Server 2007. Through the use of out-of-the-box application services, developers can build richer applications with less code.
[edit]What is the difference between Microsoft Office SharePoint Server 2007 for Internet sites and Microsoft Office SharePoint Server 2007?
Microsoft Office SharePoint Server 2007 for Internet sites and Microsoft Office SharePoint Server 2007 have identical feature functionality. While the feature functionality is similar, the usage rights are different.

If you are creating an Internet, or Extranet, facing website, it is recommended that you use Microsoft Office SharePoint Server 2007 for Internet sites which does not require the purchase client access licenses. Websites hosted using an “Internet sites” edition can only be used for Internet facing websites and all content, information, and applications must be accessible to non-employees. Websites hosted using an “Internet sites” edition cannot be accessed by employees creating, sharing, or collaborating on content which is solely for internal use only, such as an Intranet Portal scenario. See the previous section on licensing for more information on the usage scenarios.

[edit]What suites of the 2007 Microsoft Office system work with Office SharePoint Server 2007?
Office Outlook 2007 provides bidirectional offline synchronization with SharePoint document libraries, discussion groups, contacts, calendars, and tasks.

Microsoft Office Groove 2007, included as part of Microsoft Office Enterprise 2007, will enable bidirectional offline synchronization with SharePoint document libraries.

Features such as the document panel and the ability to publish to Excel Services will only be enabled when using Microsoft Office Professional Plus 2007or Office Enterprise 2007.

Excel Services will only work with documents saved in the new Office Excel 2007 file format (XLSX).

[edit]How do I invite users to join a Windows SharePoint Services Site? Is the site secure?
SharePoint-based Web sites can be password-protected to restrict access to registered users, who are invited to join via e-mail. In addition, the site administrator can restrict certain members’ roles by assigning different permission levels to view post and edit.

[edit]Can I post any kind of document?
You can post documents in many formats, including .pdf, .htm and .doc. In addition, if you are using Microsoft Office XP, you can save documents directly to your Windows SharePoint Services site.

[edit]Can I download information directly from a SharePoint site to a personal digital assistant (PDA)?
No you cannot. However, you can exchange contact information lists with Microsoft Outlook.

[edit]How long does it take to set up the initial team Web site?
It only takes a few minutes to create a complete Web site. Preformatted forms let you and your team members contribute to the site by filling out lists. Standard forms include announcements, events, contacts, tasks, surveys, discussions and links.

[edit]Can I create custom templates?
Yes you can. You can have templates for business plans, doctor’s office, lawyer’s office etc.

[edit]How can I make my site public? By default, all sites are created private.
If you want your site to be a public Web site, enable anonymous access for the entire site. Then you can give out your URL to anybody in your business card, e-mail or any other marketing material. The URL for your Web site will be: http://

Hence, please take special care to name your site. These Web sites are ideal for information and knowledge intensive sites and/or sites where you need to have shared Web workspace. Remember: Under each parent Web site, you can create up to 10 sub-sites each with unique permissions, settings and security rights.

[edit]How do the sub sites work?
You can create a sub site for various categories. For example:

Departments – finance, marketing, IT
Products – electrical, mechanical, hydraulics
Projects – Trey Research, Department of Transportation, FDA
Team – Retention team, BPR team
Clients – new clients, old clients
Suppliers – Supplier 1, Supplier 2, Supplier 3
Customers – Customer A, Customer B, Customer C
Real estate – property A, property B
The URLs for each will be, for example:
You can keep track of permissions for each team separately so that access is restricted while maintaining global access to the parent site.

[edit]How do I make my site non-restricted?
If you want your site to have anonymous access enabled (i.e., you want to treat it like any site on the Internet that does not ask you to provide a user name and password to see the content of the site), follow these simple steps:

Login as an administrator
Click on site settings
Click on Go to Site Administration
Click on Manage anonymous access
Choose one of the three conditions on what Anonymous users can access:

Entire Web site
Lists and libraries
Default condition is nothing; your site has restricted access. The default conditions allow you to create a secure site for your Web site.

[edit]Can I get domain name for my Web site?
Unfortunately, no. At this point, we don’t offer domain names for SharePoint sites. But very soon we will be making this available for all our SharePoint site customers. Please keep checking this page for further update on this. Meanwhile, we suggest you go ahead and set up your site and create content for it.

[edit]What are picture libraries?
Picture libraries allow you to access a photo album and view it as a slide show or thumbnails or a film strip. You can have separate folder for each event, category, etc

[edit]What are the advantages of a hosted SharePoint vs. one that is on an in-house server?
No hardware investment, i.e. lower costs
No software to download – ready to start from the word go
No IT resources – Anyone who has used a Web program like Hotmail can use it
Faster deployment
[edit]Can I ask users outside of my organization to participate in my Windows SharePoint Services site?
Yes. You can manage this process using the Administration Site Settings. Simply add users via their e-mail alias and assign permissions such as Reader or Contributor.

[edit]Are there any IT requirements or downloads required to set up my SharePoint site?
No. You do not need to download any code or plan for any IT support. Simply complete the on-line signup process and provide us your current and correct email address. Once you have successfully signed up and your site has been provisioned, we will send a confirmation to the email address you provided.

[edit]I am located outside of the United States. Are there any restrictions or requirements for accessing the Windows SharePoint Services?
No. There are no system or bandwidth limitations for international trial users. Additionally language packs have been installed which allow users to set up sub-webs in languages other than English. These include: Arabic, Danish, Dutch, Finnish, French, German, Hebrew, Italian, Japanese, Polish, Portuguese (Brazilian), Spanish and Swedish.

[edit]Are there any browser recommendations?
Yes. Microsoft recommends using the following browsers for viewing and editing Windows SharePoint Services sites: Microsoft Internet Explorer 5.01 with Service Pack 2, Microsoft Internet Explorer 5.5 with Service Pack 2, Internet Explorer 6, Netscape Navigator 6.2 or later.
[edit]What security levels are assigned to users?
Security levels are assigned by the administrator who is adding the user. There are four levels by default and additional levels can be composed as necessary.

Reader – Has read-only access to the Web site.
Contributor – Can add content to existing document libraries and lists.
Web Designer – Can create lists and document libraries and customize pages in the Web site.
Administrator – Has full control of the Web site.
[edit]How secure are Windows SharePoint Services sites hosted by Microsoft?
Microsoft Windows SharePoint Services Technical security measures provide firewall protection, intrusion detection, and web-publishing rules. The Microsoft operation center team tests and deploys software updates in order to maintain the highest level of security and software reliability. Software hot-fixes and service packs are tested and deployed based on their priority and level of risk. Security related hot-fixes are rapidly deployed into the environment to address current threats. A comprehensive software validation activity ensures software stability through regression testing prior to deployment.

[edit]What is the difference between an Internet and an intranet site?
An internet site is a normal site that anyone on the internet can access (e.g.,,, etc.). You can set up a site for your company that can be accessed by anyone without any user name and password. The internet is used for public presence and a primary marketing tool managed typically by web programmers and a system administrator.

An intranet (or internal network), though hosted on a Web site, can only be accessed by people who are members of a specific network. They need to have a login and password that was assigned to them when they were added to the site by the site administrator. The intranet is commonly used as an internal tool for giving employees access to company information. Content is driven by business relevance, business rules and has increasingly become a common tool in larger organizations. An intranet is becoming more and more the preferred method for employees to interact with each other and the central departments in an organization, whether or not the organization has a Web presence.

[edit]What is a workspace?
A site or workspace is when you want a new place for collaborating on Web pages, lists and document libraries. For example, you might create a site to manage a new team or project, collaborate on a document or prepare for a meeting.

[edit]What are the various kinds of roles the users can have?
A user can be assigned one of the following roles

Reader – Has read-only access to the Web site.
Contributor – Can add content to existing document libraries and lists.
Web Designer – Can create lists and document libraries and customize pages in the Web site.
Administrator – Has full control of the Web site.
[edit]Can more than one person use the same login?
If the users sharing that login will have the same permissions and there is no fear of them sharing a password, then yes. Otherwise, this is discouraged.

[edit]How customizable is the user-to-user access?
User permissions apply to an entire Web, not to documents themselves. However, you can have additional sub webs that can optionally have their own permissions. Each user can be given any of four default roles. Additional roles can be defined by the administrator.

[edit]Can each user have access to their own calendar?
Yes there are two ways to do this,

by creating a calendar for each user, or
by creating a calendar with a view for each user
[edit]How many files can I upload?
There is no restriction in place except that any storage consumed beyond that provided by the base offering may have an additional monthly charge associated with them.

[edit]What types of files can I upload / post to the site?
The only files restricted are those ending with the following extensions: .asa, .asp, .ida, .idc, .idq. Microsoft reserves the right to add additional file types to this listing at any time. Also, no content that violates the terms of service may be uploaded or posted to the site.

[edit]Can SharePoint be linked to an external data source?
SharePoint data can be opened with Access and Excel as an external data source. Thus, SharePoint can be referenced as an external data source. SharePoint itself cannot reference an external data source.

But 3rd pary software can do this for you:

[edit]Can SharePoint be linked to a SQL database?
SharePoint 2007 Portal Server (MOSS2K7) allows connections to SQL based datasources via the Business Data Catalog (BDC). The BDC also allows connecting to data via Web Services.

[edit]Can I customize my Windows SharePoint Services site?
YES! Windows SharePoint Services makes updating sites and their content from the browser easier then ever.

SharePoint includes tools that let you create custom lists, calendars, page views, etc. You can apply a theme; add List, Survey and Document Library Web Parts to a page; create personal views; change logos; connect Web Parts and more.

To fully customize your site, you can use Microsoft FrontPage 2003. Specifically, you can use FrontPage themes and shared borders, and also use FrontPage to create photo galleries and top ten lists, utilize standard usage reports, and integrate automatic Web content.

[edit]Will Microsoft Office SharePoint Server 2007 run on a 64-bit version of Microsoft Windows?
Windows SharePoint Services 3.0, Office SharePoint Server 2007, Office Forms Server 2007, and Office SharePoint Server 2007 for Search will support 64-bit versions of Windows Server 2003.

[edit]How Office SharePoint Server 2007 can help you?
Office SharePoint Server 2007 can help us:

Manage content and streamline processes. Comprehensively manage and control unstructured content like Microsoft Office documents, Web pages, Portable Document Format file (PDF) files, and e-mail messages. Streamline business processes that are a drain on organizational productivity.

Improve business insight. Monitor your business, enable better-informed decisions, and respond proactively to business events.

Find and share information more simply. Find information and expertise wherever they are located. Share knowledge and simplify working with others within and across organizational boundaries.

Empower IT to make a strategic impact. Increase responsiveness of IT to business needs and reduce the number of platforms that have to be maintained by supporting all the intranet, extranet, and Web applications across the enterprise with one integrated platform.

Office SharePoint Server 2007 capabilities can help improve organizational effectiveness by connecting people, processes, and information.

Office SharePoint Server 2007 provides these capabilities in an integrated server offering, so your organization doesn’t have to integrate fragmented technology solutions itself.

[edit]What are the features that the portal components of Office SharePoint Server 2007 include?
The portal components of Office SharePoint Server 2007 include features that are especially useful for designing, deploying, and managing enterprise intranet portals, corporate Internet Web sites, and divisional portal sites. The portal components make it easier to connect to people within the organization who have the right skills, knowledge, and project experience.

[edit]What are the advanced features of MOSS 2007?
User Interface (UI) and navigation enhancements
Document management enhancements
The new Workflow engine
Office 2007 Integration
New Web Parts
New Site-type templates
Enhancements to List technology
Web Content Management
Business Data Catalog
Search enhancements
Report Center
Records Management
Business Intelligence and Excel Server
Forms Server and InfoPath
The “Features” feature
Alternate authentication providers and Forms-based authentication
[edit]What are the features of the new Content management in Office SharePoint 2007?
The new and enhanced content management features in Office SharePoint Server 2007 fall within three areas:

Document management
Records management
Web content management
Office SharePoint Server 2007 builds on the core document management functionality provided by Windows SharePoint Services 3.0, including check in and check out, versioning, metadata, and role-based granular access controls. Organizations can use this functionality to deliver enhanced authoring, business document processing, Web content management and publishing, records management, policy management, and support for multilingual publishing.

[edit]Does a SharePoint Web site include search functionality?
Yes. SharePoint Team Services provides a powerful text-based search feature that helps you find documents and information fast.

[edit]Write the features of the search component of Office SharePoint Server 2007?
The search component of Office SharePoint Server 2007 has been significantly enhanced by this release of SharePoint Products and Technologies. New features provide:

A consistent and familiar search experience.
Increased relevance of search results.
New functions to search for people and expertise.
Ability to index and search data in line-of-business applications and
Improved manageability and extensibility.
[edit]What are the benefits of Microsoft Office SharePoint Server 2007?
Provide a simple, familiar, and consistent user experience.
Boost employee productivity by simplifying everyday business activities.
Help meet regulatory requirements through comprehensive control over content.
Effectively manage and repurpose content to gain increased business value.
Simplify organization-wide access to both structured and unstructured information across disparate systems.
Connect people with information and expertise.
Accelerate shared business processes across organizational boundaries.
Share business data without divulging sensitive information.
Enable people to make better-informed decisions by presenting business-critical information in one central location.
Provide a single, integrated platform to manage intranet, extranet, and Internet applications across the enterprise.
[edit]Will SharePoint Portal Server and Team Services ever merge?
The products will come together because they are both developed by the Office team.

[edit]What does partial trust mean the Web Part developer?
If an assembly is installed into the BIN directory, the code must be ensured that provides error handling in the event that required permissions are not available. Otherwise, unhandled security exceptions may cause the Web Part to fail and may affect page rendering on the page where the Web Part appears.

[edit]How can I raise the trust level for assemblies installed in the BIN directory?
Windows SharePoint Services can use any of the following three options from ASP.NET and the CLR to provide assemblies installed in the BIN directory with sufficient permissions. The following table outlines the implications and requirements for each option.

Option Pros Cons

Increase the trust level for the entire virtual server. For more information, see “Setting the trust level for a virtual server” Easy to implement.

In a development environment, increasing the trust level allows you to test an assembly with increased permissions while allowing you to recompile assemblies directly into the BIN directory without resetting IIS. This option is least secure.

This option affects all assemblies used by the virtual server. There is no guarantee the destination server has the required trust level. Therefore, Web Parts may not work once installed on the destination server.

Create a custom policy file for your assemblies. For more information, see “How do I create a custom policy file?” Recommended approach.

This option is most secure.

An assembly can operate with a unique policy that meets the minimum permission requirements for the assembly.

By creating a custom security policy, you can ensure the destination server can run your Web Parts.

Requires the most configuration of all three options. Install your assemblies in the GAC

Easy to implement. This grants Full trust to your assembly without affecting the trust level of assemblies installed in the BIN directory.

This option is less secure.

Assemblies installed in the GAC are available to all virtual servers and applications on a server running Windows SharePoint Services. This could represent a potential security risk as it potentially grants a higher level of permission to your assembly across a larger scope than necessary

In a development environment, you must reset IIS every time you recompile assemblies.

Licensing issues may arise due to the global availability of your assembly.

[edit]Does SharePoint work with NFS?
Yes and no. It can crawl documents on an NFS volume, but the sharepoint database or logs cannot be stored there.

[edit]How is SharePoint Portal Server different from the Site Server?
Site Server has search capabilities but these are more advanced using SharePoint. SPS uses digital dashboard technology which provides a nice interface for creating web parts and showing them on dashboards (pages). SS doesn’t have anything as advanced as that. The biggest difference would be SPS document management features which also integrate with web folders and MS Office.

[edit]What would you like to see in the next version of SharePoint?
A few suggestions:

SPS and STS on same machine
Tree view of Categories and Folders
General Discussion Web Part
Personalization of Dashboards
Role Customization
Email to say WHY a document has been rejected for Approval
More ways to customize the interface
Backup and restore an individual Workspaces
Filter for Visio
Better way to track activity on SPS
Ability to Save as from Adobe to space on My Network Places
[edit]Why Sharepoint is not a viable solution for enterprise wide deployments?
Planning an enterprise deployment using SharePoint features is a very difficult task unless you can establish a Service Oriented Architecture, using AD for managing security with well defined roles based information access(EISA). Sounds reasonable, although it seems difficult to deploy with the tools limitations in document storage.

Document management does not scale beyond a single server, but scales great within a single server. For example, a quad Xeon machine with 4GB of RAM works great for a document management server that has about 900,000 – 1,000,000 document, but if you need to store 50,000,000 document and want to have them all in one single workspace then it does not scale at all. If you need a scenario like this, you need to plan your deployment right and it should scale for you, it just does not right out of the box. If you are using your server as a portal and search server most for the most part it scales great. You can have many different servers crawl content sources and have separate servers searching and serving the content.

If you have < 750,000 documents per server and fewer than 4 content sources and fewer than 50,000 users, SPS should scale just fine for your needs with the proper planning.

[edit]What are the actual advantages of SharePoint Portal Services (SPS) over SharePoint Team Services (STS)?
SharePoint Portal Services (SPS) has MUCH better document management. It has check-in, check-out, versioning, approval, publishing, subscriptions, categories, etc. STS does not have these features, or they are very scaled back. SharePoint Portal Services (SPS) has a better search engine, and can crawl multiple content sources. STS cannot. STS is easier to manage and much better for a team environment where there is not much Document Management going on. SPS is better for an organization, or where Document Management is crucial.

[edit]How Does SharePoint work?
The browser sends a DAV packet to IIS asking to perform a document check in. PKMDASL.DLL, an ISAPI DLL, parses the packet and sees that it has the proprietary INVOKE command. Because of the existence of this command, the packet is passed off to msdmserv.exe, who in turn processes the packet and uses EXOLEDB to access the WSS, perform the operation and send the results back to the user in the form of XML.

[edit]How do I open an older version of a document?
Normally, all previous versions are located in the shadow, so if you right click a published document from within the web folders, go to properties and then the third tab, versions you can view older versions.

If you want to do this in code:

strURL = “url of the last published version”
Set oVersion = New PKMCDO.KnowledgeVersion
Set prmRs = oVersion.VersionHistory(strURL)
Set oVersion = Nothing
prmRS will contain a recordset, which contains the url to the old versions in the shadow.

[edit]Why do the workspace virtual directories show the error “stop sign” symbol in the IIS snap-in?
If World Wide Web Publishing Service (W3SVC) starts before Microsoft Exchange Information Store (MSExchangeIS), “stop sign” symbols appear under the Default Web Site folder of the Internet Information Services console in Microsoft Management Console (MMC).

There is a dependency between the local paths of the SharePoint Portal Server virtual directories and the MSExchangeIS. You must start MSExchangeIS first, followed by W3SVC.

Complete the following steps to prevent the stop signs from appearing each time you restart:

Change the Startup type for W3SVC to Manual.
Restart the server. The MSExchangeIS service starts automatically.
Start W3SVC.
[edit]What newsgroups are available?
There are two,

microsoft.public.sharepoint.portalserver and
[edit]What is SharePoint from a Technical Perspective?
Technically SharePoint illustrates neatly what Microsoft’s .net strategy is all about: integrating Windows with the Web. Microsoft has previously made accessing stuff on a PC easier, (Windows) then on a network (NT) and now on the web (.NET). SharePoint is an application written to let a user access a web accessible directory tree called the Web Storage System.

SharePoint was written with a set of technologies that allow the programmer to pass data, functions, parameters over HTTP, the web’s medium. These are XML, XSL and SOAP, to name a few I understand the basics of!

To the user it looks easy, like Hotmail, but every time they click a button or a link, a lot has to happen behind the scenes to do what they want to do quickly and powerfully. Not as easy as you might think, but SharePoint does it for you. Accessing this Web storage system and the server itself is also done using technologies like ADO, CDO, PKMCDO, LDAP, DDSC, ADSC. More on these later. SharePoint is a great example of how the Internet Platform can be extended and integrated into an existing well adopted technology, Windows.

[edit]What is SharePoint from an Administration Perspective?
Administering SharePoint mainly consists of setting it up, which is much easier than you expect, adding the content, which can be just dragging and dropping in whole directory structures and files, and then organizing the files better by giving them categories or other metadata. This is done either through the Web interface or through the SharePoint Client: a program what means you can access SharePoint as a Web folder and then right-click files to select options like “edit profile”. Or add files by dragging them in individually or in bulk.

Setting the security is also important, using NT accounts, either NT4 or Active Directory (or both in mixed mode) you can give users access to files/folders the same way as you do in standard Windows. Users can be grouped and the groups given access privileges to help manage this better. Also SharePoint has 3 Roles that a User or Group can be given on a particular item. Readers can see the item (i.e. document/file or folder) but not change it, Authors can see and edit items and coordinators can set security privileges for the part of the system they have control over. Thus, you could set 12 different coordinators for 12 different folder trees, and they could manage who can do what within that area only.

[edit]What is SharePoint from a Users Perspective?
From a Users perspective SharePoint is a way of making documents and folders on the Windows platform accessible over the web. The user visits the SharePoint Portal web page, and from there they can add documents, change documents & delete documents. Through this Portal, these documents are now available for discussion, collaboration, versioning and being managed through a workflow. Hence the name “Share-Point”. Details about the document can be saved too, such as: who wrote it, when, for whom, its size, and version, category or target audience. These can then be used to find the document through SharePoint’s Search facility. Even documents not “in” SharePoint can be included in the search engine’s index so they become part of the portal. All in all, it’s a great way to get stuff up on the web for users with average technical skills, and for administrators to manage the content.

[edit]What are the various Sharepoint 2003 and Exchange integration points?
[edit]Link to Outlook
This is a button on contacts or events lists that lets Outlook 2003 add a pst file named Sharepoint Folders and it links to the data on the site. It’s read-only, but you could make the home page for that PST be the Sharepoint site for easier viewing. The link to outlook feature seems more to be where some can public a calendar, but not want too much collaboration. For example, a holiday schedule, company meeting schedule, etc, can be made available for people to be able to view from Outlook without having to go to a web browser. Another nice thing about OL2K3 is that you can compare these calendars with others side by side.

[edit]Searching Public Folders
With SPS you can index Exchange’s public folders with the search engine so that all that precious public folder content is searchable. You’ll want to look at content sources and indexing in Sharepoint administration.

[edit]Displaying Public Folders in a web part
Since exchange web-enables public folders, you can create a web part that displays that content. IE, http://exchangeserver/Public/IT/Helpdesk will display the IT/Helpdesk public folder via OWA. So you add the Page Viewer web part to a page and point it at that URL. The key here is to add ?cmd=contents to the end of the url if you don’t want the navigator pane on the left.

[edit]Smart web parts
Some of the web parts that come with SPS allow you to add a web part to a page that actually takes the users outlook info (calendar, inbox, contacts, tasks) and put them into the page.

The SmartPart Web Part project template for Visual Studio allows developers to create quickly a project which contains the base infrastructure to:

   * write a web user control (ASCX)
   * wrap the user control in a SmartPart instance
   * generate a SharePoint Solution file (WSP) for easy deployment
   * generate a setup package for a wizard driven installation

[edit]Can SharePoint compare two document versions?
“In Word 2003, you can compare documents side by side. Open two documents. Then, from the Window menu of one of them, select the Compare Side By Side command. If you have only two documents open, the command will automatically choose to compare them. If you have three or more documents open, you’ll have to select which document to compare with the current file.

A floating toolbar with two buttons will open. If the button on the left is selected, Word will scroll both documents at the same time. Press the button on the right side of the toolbar to return to where the cursor was located when you started comparing.”

[edit]What are the integration differences between SPS 2003 and the various Office versions?
SPS webpage can detect you have installed the Office 2003 and run local dll to implement some SPS function, e.g. multi-file upload only works when you have office 2003 installed.

Integration with Office XP is gone.

You will get guys telling you that you can integrate with SPSv2 if you install a backwards compatible document library – but that’s really just putting a bit of SPS 2001 on the server.

Believe me, check-in, check-out, which are themselves very basic, are not available from inside Office XP, or even from the context menu in Windows Explorer.

The ONLY option you have is to use the web interface to check-in or check-out.

1. Add new document to Document Library in SharePoint using C#

Here is the code for adding new document to document library using C#.  I have created a page with a file upload control and a button. When user clicks on button the selected document will be uploaded to specific document library. You need to add reference to Microsoft.SharePoint DLL to make this code running.

if (FileUpload1.PostedFile != null)
            if(FileUpload1.PostedFile.ContentLength > 0)
                   System.IO.Stream strm = FileUpload1.PostedFile.InputStream;

                   byte[] byt = new byte[
                           Convert.ToInt32 (FileUpload1.PostedFile.ContentLength)];

                   strm.Read(byt, 0, Convert.ToInt32

                // Open site where document library is created.
                using (SPSite objSite = new SPSite(“http://server:port/”))
                    using (SPWeb objWeb = objSite.OpenWeb())
                        SPFolder mylibrary = objWeb.Folders[“Name of Document Library”];

                        // Set AllowUnsafeUpdates = true to avoid security error
                        objWeb.AllowUnsafeUpdates = true;

                                                                (FileUpload1.PostedFile.FileName), byt);

     Above code first reads the uploaded file in Stream and than uploads it on document library.
Nishant Rana’s Weblog
Everything related to Microsoft .NET technology
Code snippets My CRM Learning Useful CRM Tools Links Head First OOAD(C#) News for Microsoft Lovers Posted by: Nishant Rana | June 26, 2008 Programmatically uploading and setting permission to a document in a document library in SharePointWe can use the following code for uploading a document to document library.
// create a filestream object and open an existing file for reading its contents

FileStream oFileStream = File.OpenRead(@”C:\G.doc”);

byte[] content = new byte[oFileStream.Length];

// store the contents in a byte array

oFileStream.Read(content, 0, (int)oFileStream.Length);

// create an SPSIte object

using (SPSite objSite = new SPSite(“http://d-1246?))


// get reference to the web application or web site

using (SPWeb objWeb = objSite.OpenWeb())


// get reference to the document library. Proposal – name of the document library

SPFolder mylibrary = objWeb.Folders[“Proposal”];

objWeb.AllowUnsafeUpdates = true;

// add the file to the document library and update it

SPFile myFile = mylibrary.Files.Add(“MyProposal.doc”, content, true);


// get the reference to the file just uploaded as a SPListItem for setting permissions

SPListItem myListItem = myFile.Item;

// HasUniqueRoleAssignments – returns false if it inherits permission from parent else true


// BreakRoleInheritance – breaking role inheritance so that we can define our own permissions


// webroledefinitions – Full Right, Design, Contribute and Read

SPRoleDefinitionCollection webroledefinitions = objWeb.RoleDefinitions;

// group – different groups created in that site

SPGroup group = objWeb.SiteGroups[“MyGroup”];

SPRoleAssignment roleassignment = new SPRoleAssignment(group);



// same for the user as well

SPUser user = objWeb.SiteUsers[@”domainname\username”];

SPRoleAssignment roleassignment1 = new SPRoleAssignment(user);

roleassignment1.RoleDefinitionBindings.Add(webroledefinitions[“Full Control”]);





Download all files from SharePoint Library

Now, we are going to see how we can download all documents(incluing sub folders) from SharePoint Library.

First of all,we have get all documents from SharePoint Library. The following code help us to get all the documents including Subfolders.
//Get the Document Library and its view
SPList list = web.Lists[“Test Document”];
SPView view = list.Views[“All Documents”];
//Query all documents in Library including files under subfolders
SPQuery squery = new SPQuery(view);
squery.ViewAttributes = “Scope=\”Recursive\””;
SPListItemCollection items = list.GetItems(squery);

Now we have to write a code for downloaing documents,
//Read all documents and write those files to Local System
foreach (SPListItem item in items)
byte[] binfile = item.File.OpenBinary();
FileStream fstream = new FileStream(“F:\\” + item.File.Name, FileMode.Create, FileAccess.ReadWrite);
fstream.Write(binfile, 0, binfile.Length);
4.Programmatically creating folder in SharePoint Document library
SPSite _MySite = new SPSite(“http://adfsaccount:2222/“);
SPWeb _MyWeb = _MySite.OpenWeb();
SPDocumentLibrary _MyDocLibrary = (SPDocumentLibrary) _MyWeb.Lists[“My Documents”];
SPFolderCollection _MyFolders = _MyWeb.Folders;
_MyFolders.Add(“http://adfsaccount:2222/My%20Documents/” + txtUpload.Text + “/”);
MessageBox.Show(“Docuemnt Created”);

Podcasting Kit for SharePoint
PKS is freely available on codeplex.  It allows you to use MOSS as a podcasting platform.  Users can upload documents/podcasts/videocasts along with secondary files.  This is great if you want to store your sample code, documentation, etc. along with your podcast.

6.What is the External Collaboration Toolkit for SharePoint?

The External Collaboration Toolkit for SharePoint provides guidance and tools to deploy a pre-built, customizable SharePoint solution that teams can use to collaborate with those outside the firewall.  At the same time, the toolkit helps ensure that sensitive data on these systems is protected.

Once the ECTS is installed, your users can be up and running with a secure, SharePoint-based team site in minutes.  They can easily invite external users to collaborate, sharing documents that are centrally located on a SharePoint site inside the firewall.  Administrators can require administrative approval for all new sites and users, or they can delegate this control to end users and free up time for other tasks.

Where do I access the External Collaboration Toolkit for SharePoint?

The ECTS is available now at


My Sharepoint articles

June 18, 2009

Creation of a SPGridview Webpart having Pagination, Sorting, Filtering Functionalities in Sharepoint Site in Step by Step Manner

Creating CheckAll UncheckAll Gridview Webpart with Paging, Sorting Functionalities in Sharepoint 2007 in a Step by Step Manner

Part 1: Installing Features and Adding Breadcrumbs to Custom Pages in Sharepoint Central Administrat