Jean Paul's Blog

There are 2 types of People in the World, One who Likes SharePoint and..

    Advertisements
  • Microsoft MVP

  • MindCracker MVP

  • CodeProject MVP

  • eBook on SharePoint 2010

  • eBook on Design Patterns

  • eBook on Windows Azure

  • NLayers Framework @ CodePlex

  • MSDN Forums

  • .Net vs. Java

    Due to Public Demand
  • Advertisements

Archive for June, 2012

How to create a List in SharePoint using Client Object Model?

Posted by Paul on June 30, 2012

ClientContext clientContext = new ClientContext(“http://url”);

ListCreationInformation listCreationInformation = new ListCreationInformation();
listCreationInformation.Title = “New List Title”;
listCreationInformation.TemplateType = (int)ListTemplateType.Tasks;

list = clientContext.Web.Lists.Add(listCreationInformation);

clientContext.ExecuteQuery();

Advertisements

Posted in C# | Tagged: , , | 2 Comments »

SharePoint 2010 – Create Crawl Schedule

Posted by Paul on June 29, 2012

In this article we can explore how to create a crawl schedule for the Search.

Following are the steps involved:

1. Open Central Administration web site as shown below:

clip_image002

2. Click on the Manage service applications link as highlighted above:

clip_image004

3. Click on the Search Service Application as highlighted above:

clip_image006

4. Click on the Content Sources link as highlighted above:

clip_image008

5. Click on the Local SharePoint sites cell and in the page on the right side you can see the Crawl Schedules.

clip_image010

You can see two item: Full Crawl and Incremental Crawl

Full Crawl

To start with we have to use Full Crawl. This will be time consuming and provides the starting point for Incremental Crawls. Full Crawl replaces all existing crawl contents regardless they have changed or not.

Incremental Crawl

These are faster crawls as they crawl only modified crawls. A Full Crawl has to be performed previously to do the Incremental Crawl.

6. Use the Create Schedule link to create a new Crawl Schedule

clip_image012

7. Enter the details in the appearing dialog and click the OK button

clip_image014

8. Click the OK button on the page

clip_image016

You can see that the site is reflected with the new crawl schedule:

clip_image018

References

http://social.technet.microsoft.com/wiki/contents/articles/full-and-incremental-crawls-in-microsoft-office-sharepoint-server-2007-search.aspx

Summary

In this article we have seen how to create a crawl schedule.

Posted in C# | Tagged: , | Leave a Comment »

SharePoint 2010 – Create Crawl Schedule

Posted by Paul on June 29, 2012

In this article we can explore how to create a crawl schedule for the Search.

Following are the steps involved:

1. Open Central Administration web site as shown below:

clip_image002

2. Click on the Manage service applications link as highlighted above:

clip_image004

3. Click on the Search Service Application as highlighted above:

clip_image006

4. Click on the Content Sources link as highlighted above:

clip_image008

5. Click on the Local SharePoint sites cell and in the page on the right side you can see the Crawl Schedules.

clip_image010

You can see two item: Full Crawl and Incremental Crawl

Full Crawl

To start with we have to use Full Crawl. This will be time consuming and provides the starting point for Incremental Crawls. Full Crawl replaces all existing crawl contents regardless they have changed or not.

Incremental Crawl

These are faster crawls as they crawl only modified crawls. A Full Crawl has to be performed previously to do the Incremental Crawl.

6. Use the Create Schedule link to create a new Crawl Schedule

clip_image012

7. Enter the details in the appearing dialog and click the OK button

clip_image014

8. Click the OK button on the page

clip_image016

You can see that the site is reflected with the new crawl schedule:

clip_image018

References

http://social.technet.microsoft.com/wiki/contents/articles/full-and-incremental-crawls-in-microsoft-office-sharepoint-server-2007-search.aspx

Summary

In this article we have seen how to create a crawl schedule.

Posted in C# | Tagged: , | Leave a Comment »

Manage Search Scope

Posted by Paul on June 29, 2012

In this article we can experiment with managing search scope.

Search Scope allows the user to search within a particular scope. By default SharePoint provides entire site collection search. If the user knows the search item is within a file system, he/she can specify the scope to narrow the search results. This will allows in faster locating of the context item.

The default search scope is All Sites.

Adding a new Search Scope

1. Open SharePoint Central Administration > Manage Service Applications > Search Service Application page

image

2. Click on the Scopes link as highlighted above

image

3. Click on the New Scope link from the appearing page. Enter the details as shown below and click the OK button.

image

4. Click the Add rules for our newly created scope as shown below

image

5. Set the properties as shown below (Pointing to our File System Content Source)

image

Click the OK button to continue. Now we are ready with a Scope set with rules. But in order to view the scope in Search drop down list, we need to do the following steps.

6. Click Search Administration > Start Updating Now link as shown below

image

7. Now open our default SharePoint site and open the Site Settings > Search scopes

image

8. Click the Display Groups button from the top bar as shown below

image

9. Select the Edit Display Group option as shown below.

image

10. Select the File System Scope and click the OK button

image

Now the Search Scope is ready within our site. You can experiment it by opening a site and selecting the scope from the scope drop down list.

image

References

http://office.microsoft.com/en-us/sharepoint-server-help/managing-search-scopes-HA001160438.aspx

Summary

In this article we can experimented the manage search scope feature of SharePoint. In the real world scenario Administrators need to configure different search scopes for different site collections.

Posted in C# | Tagged: , | Leave a Comment »

SharePoint 2010 Project – Foster – Part 1

Posted by Paul on June 24, 2012

As promised please find the Part 1 of the project named Foster.

Part 1: Requirement Specification

(In this document I have not included complex business rules/attributes to stay more focused on SharePoint skills)

image

Please download the above link and read it 2-3 times to get an overview of the project.

I will be coming up with the next part soon!

Note: After downloading you might need to Unblock the file to start reading.

Posted in C# | Tagged: , , | Leave a Comment »

SharePoint 2010 Project – Foster – Part 1

Posted by Paul on June 24, 2012

As promised please find the Part 1 of the project named Foster.

Part 1: Requirement Specification

(In this document I have not included complex business rules/attributes to stay more focused on SharePoint skills)

image

Please download the above link and read it 2-3 times to get an overview of the project.

I will be coming up with the next part soon!

Note: After downloading you might need to Unblock the file to start reading.

Posted in C# | Tagged: , , | Leave a Comment »

Coming Soon: SharePoint 2010 Projects!!!

Posted by Paul on June 21, 2012

Hello Friends, Thank You all for supporting me through the community posts and replies.

image

Now I would like to go ahead one level more by creating real world SharePoint Projects.  The motivation was given from my colleagues and friends who wanted to see SharePoint in Action in real world scenarios.

image

Above All it will be based on the SDLC format of:

  1. Requirement Specification
  2. Design Document
  3. Implementation
  4. Documentation

As always i am open for queries, helps and discussing your opinions on architectural decisions.

Hope You will enjoy it!

Posted in C# | Tagged: , , | 4 Comments »

Search – Content Sources

Posted by Paul on June 20, 2012

In this article we can explore Content Sources and how to add a new Content Source.

Content Sources

Content Source represents the origin of content. As SharePoint handles various contents like Database, File System etc. there should be a Indexing Service to handle all these sources.

Please have a note that SQL Server is having Full Text Search index, but SharePoint has its own Indexing engines.

By default SharePoint searches in the site collection and document libraries.

Using Custom Content Source configuration we can make SharePoint search the possible areas:

· File System Drives

· Network Drives

· Lotus Notes Data

· Web Sites

Adding new Content Source

In this example we are trying to add a File System content source. After adding, the user will be able to search on the files and contents inside it.

Following are the steps involved:

1. Create a Share Folder named Contents with a Text File inside it and make Read/Write permissions to Everyone

clip_image002

Ensure that the above folder contains a text file with data for eg: MyTodo

2. Open the Central Administration web site and click on Manage Service Applications link

clip_image004

3. Click on Search Service Applications from the appearing page

clip_image006

4. Click the Content Sources link from the left pane

clip_image008

5. Click on the New Content Source link from the appearing page

clip_image010

6. Enter the following details in the Content Source page

clip_image012

Click the OK button and the Crawler will be performing a crawl.

7. Go back to the main site and enter the keyword to search for (MyToDo). You can view the following results.

clip_image014

This concludes our article on adding Content Source and doing a sample search.

Viewing Crawl History

We can always view the crawl log to check the activity was successful and view the errors if not. Use the View Crawl Log command to view this.

clip_image016

Starting Crawls

We can start / stop / pause crawls manually by using the command bar as shown below. Please note that only after a full crawl the data will be searchable.

clip_image018

Summary

In this article we have explored how to add a content source inside SharePoint site.

Posted in C# | Tagged: , | Leave a Comment »

Search – Content Sources

Posted by Paul on June 20, 2012

In this article we can explore Content Sources and how to add a new Content Source.

Content Sources

Content Source represents the origin of content. As SharePoint handles various contents like Database, File System etc. there should be a Indexing Service to handle all these sources.

Please have a note that SQL Server is having Full Text Search index, but SharePoint has its own Indexing engines.

By default SharePoint searches in the site collection and document libraries.

Using Custom Content Source configuration we can make SharePoint search the possible areas:

· File System Drives

· Network Drives

· Lotus Notes Data

· Web Sites

Adding new Content Source

In this example we are trying to add a File System content source. After adding, the user will be able to search on the files and contents inside it.

Following are the steps involved:

1. Create a Share Folder named Contents with a Text File inside it and make Read/Write permissions to Everyone

clip_image002

Ensure that the above folder contains a text file with data for eg: MyTodo

2. Open the Central Administration web site and click on Manage Service Applications link

clip_image004

3. Click on Search Service Applications from the appearing page

clip_image006

4. Click the Content Sources link from the left pane

clip_image008

5. Click on the New Content Source link from the appearing page

clip_image010

6. Enter the following details in the Content Source page

clip_image012

Click the OK button and the Crawler will be performing a crawl.

7. Go back to the main site and enter the keyword to search for (MyToDo). You can view the following results.

clip_image014

This concludes our article on adding Content Source and doing a sample search.

Viewing Crawl History

We can always view the crawl log to check the activity was successful and view the errors if not. Use the View Crawl Log command to view this.

clip_image016

Starting Crawls

We can start / stop / pause crawls manually by using the command bar as shown below. Please note that only after a full crawl the data will be searchable.

clip_image018

Summary

In this article we have explored how to add a content source inside SharePoint site.

Posted in C# | Tagged: , | Leave a Comment »

SharePoint 2010 – Search

Posted by Paul on June 20, 2012

In this article we can explore one of the core features of SharePoint. It is considered to be the Enterprise Feature of SharePoint. SharePoint allows configuration of Search based on different parameters. In short we can configure the breadth and depth of the search.

Search Architecture

Inside SharePoint 2010 Search is built as a service application. The Search Engine can Index SharePoint Sites, External contents, Files, Web sites etc.

Following are the server roles inside the SharePoint Search:

1. Crawler

2. Indexer

3. Query Servers

4. Search Center

Crawlers represent small programs which are scheduled to run on specific intervals. The Crawlers pass through each Content Source and Index the words in one location. These programs will be scanning Documents, Files and other Content Sources. Crawling consists of Full Crawl and Incremental Crawl. We can manually start the crawling process as well as schedule it.

The Indexer will create index files which contains the words and corresponding content source information for easier access. The indexing server can be configured to be a separate machine in a farm.

As the crawler will be encountering lots of file types like Word Document, PDF Document, Excel Document, Web sites, Text Files etc. it will be run out of logic on indexing these. We need to specify external Index Filters to tell how to index those file types. These Index Filters are also known as IFilter. The IFilter reads the contents of the file, creates the index keywords based on the content. Administrators need to configure each file type with an appropriate IFilter.

The Query Server is responsible for handling user search queries. In a farm environment query server can be configured to be a separate machine. The query serve operates on the index files for returning search results.

Search Center is a site inside SharePoint 2010 oriented towards Search. It allows configuring of Results, Advanced Search options, Navigation Elements etc. The user can create his own Search Site by using the Basic Search Center template.

Experimenting with Search

Now we can start experimenting with the Search User Interface and the functionality. The default Search box is available on the site as shown below:

clip_image002

Now we can try searching some text. Enter the address word of a contact and click the search button.

clip_image004

You can see the following results showing the data from Manager List and Edit form.

clip_image006

The search result fetched the contents of all list items inside the site. Now we can try searching with keyword Manager. The result will include the Manager list item name too.

clip_image008

References

http://technet.microsoft.com/en-us/sharepoint/ee518667

http://technet.microsoft.com/en-us/library/cc263144(office.12).aspx

http://msdn.microsoft.com/en-us/library/ms545957(v=office.12).aspx

Summary

In this article we have learnt the Search feature of SharePoint. Although Search is configured by SharePoint Administrators still the Developer can use the extended Search web services, Programmatic retrieval of content using Object Model etc.

Posted in C# | Tagged: , | Leave a Comment »