About Me

Hi I am Saritha working as Sharepoint Consultant

Wednesday, April 13, 2011

WSS 3.0 - Move a subsite with subsites

I'm working in a test WSS 3.0 environment and I would like to be able to move a subsite with subsites to another environment.  There are several ways to move a WSS 3.0 site.  The first one I tried almost worked.  I will document my attempts (and reason each attempt was or was not successful here. 
SharePoint Designer
The technique:
  • Create a placeholder for the new location of the site
    • Use WSS 3.0 browser
      • Create a site using the Blank Site template.
  • Create a backup of the site to be moved
    • Use SharePoint Designer
      • Open the site to be moved
      • On the Site Menu - point to Administration - Backup Web Site - Check Include Subsites
      • Creates a .cmp file
  • Restore the backup to the new location
    • Use SharePoint Designer
      • Open the site (new location)
      • On the Site Menu - point to Administration - Restore Web Site
      • Use the .cmp file 
Limitations:
  • The site hiearachy for the new location must be the same as the original location. 
    • For example: If you have
      • Portal Site - Projects Site - IT Projects Site - Project A Site - Project A Documentation Site - Project A Final Dcoumentation Site
      •  you cannot move it  to  move it to
      • Portal Site - Project A Documentation
  • There is a size limitation of 25MB

SharePoint Site Template
The Technique:
  • Create a Site Template
    • Using WSS 3.0 Browser:
      • Save the site you want to move as a template – include content
      • If moving to a different site collection:
        • Go to Site Gallery (at top level)
        • Save the template to a good place in the file system (like your desktop)
        • Go to the root site of the Site Collection of the new location
        • Go to the Site Gallery
        • Upload the saved site template (.stp file)
      • Browse to the parent site of the new location
      • Create a new site with the template you just uploaded (Select a template – Custom tab)
Limitations:
  • Subsites are not included
STSADM Export / Import
The Techique
  • Use STSADM command line tool
  • Export the subsite to a .bat file
  • Import the .bat file to the new site location
  • Must have the following permissions:
  • login account for SQL server for SharePoint databases
  • Site Collection Administrator for new location (?and maybe original location)
Results
  • Subsite and subsites were restored
  • Used -includeusersecurity parameter and SharePoint groups and users in these groups were moved
Limitations
  • STSADM is not user friendly with error messages.  Check the Application Event Log.  The message received in the command window may not be indicative of the true problem.

Friday, April 8, 2011

How to configure PDF iFilter for SharePoint Server 2010 or Search Server 2010

Introduction

I recently installed and configured Search Server 2010 Express on my VMware machine for evaluation purposes. Once I configured basic steps to configure Search Centre site and necessary settings, I decided to install PDF iFilter (x64). Last year, I posted a similar article on how to install and configure PDF iFilter for SharePoint 2007 (64bit), which can be found at http://www.mossgurus.com/adnan/Lists/Posts/Post.aspx?ID=9. I didn't find a single decent article on Google, which clearly explain the process of installing and configuring PDF iFilter for SharePoint Server 2010 or Search Server 2010 Express edition. So I decided to follow my own article and I was hoping that it should be straight forward to install and configure PDF iFilter for SharePoint 2010. Apart from updating the registry settings required to update GUID for .pdf, remaining steps are similar.
Follow the steps below to install and configure PDF iFilter on SharePoint Server 2010 or Search Server Express 2010.
  1. Install PDF iFilter 9.0 (64 bit) from here.
  2. Download PDF icon file from pdf16.gif and copy at C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\IMAGES\.
  3. Add the following entry in docIcon.xml file, which can be found at C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\XML.
    <Mapping Key="pdf" Value="pdf16.gif" /> 
  4. Add PDF file type on the Manage File Type page under Search Service Application.
  5. Open registry by executing regedit on the Start --> Run.
  6. Navigate to the following location:
    \\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office Server\
    14.0\Search\Setup\ContentIndexCommon\Filters\Extension 
  7. Right-click Extension, a menu will appear.
  8. Click New--> Key to create a new key for .pdf. See screen shot below:
  9. Enter .pdf and save key.
  10. Now add the following GUID in the default value as shown in the figure below.
    {E8978DA6-047F-4E3D-9C78-CDBE46041603} 
  11. If you are configuring SharePoint Server 2010, then restart Search service by executing the following command on the command line:
    net stop osearch 
    net start osearch 
  12. If you are configuring PDF iFilter on Search Server 2010, then restart the SharePoint Server Search 14 service as shown in the figure below:
  13. Perform incremental to include PDF files.
  14. PDF iFilter is successfully configured. Now you can search for the content of PDF file. See screen shot below:
Note: SharePoint Server 2010 or Search Server 2010 Express provides out of the box search support for .ZIP files, so you download and have to install Microsoft Filter pack as you used to do with MOSS 2007.
I do hope that you will find this article useful. Please leave your comments.

Friday, December 10, 2010

Convert Excel Forms into InfoPath Forms




Win FREE SharePoint Books from Apress


Problem

There may be times when users have created forms in Excel or Word, but we need them in SharePoint in a web-based version. How can I handle that easily using InfoPath? (read more...)

Solution

The solution is to use InfoPath's import feature which can convert forms from Excel/word.

I have an Excel form which looks like the following:



Now open an instance of InfoPath 2007 and you can see an option of "Import a form". Click on it.



You will be prompted for a destination type from where you want to import a form. It could be either an Excel or Word form. For now, select "InfoPath importer for Excel workbooks"



Click on Browse to select the Excel form file.



Click on options, to customize the default options (for instance, whether you want to detect repeating tables or not, to convert cells containing formulas to textbox and others). For now, leave the default settings and click OK.



Click on 'Finish' and now you can see that InfoPath has created a similar kind of structure and relative fields in the form structure.



This is a great method of having your users design a form in a tool they are familiar with, while minimizing your development time.

Tuesday, December 7, 2010

Configuring Enterprise Search in SharePoint 2010


We all have to agree that search plays an integral part of any successful SharePoint deployment and is an area that Microsoft continues to invest in with each new release of SharePoint. Microsoft went as far as acquiring FAST 2 years ago which it now offers as a separate add-on to SharePoint for those willing to invest in high end enterprise search.  In addition to FAST, SharePoint 2010 search comes in a number of flavors each offering their own feature set and capabilities which I have duplicated at the end of this article as an Appendix for convenience.
Today we will introduce SharePoint Server 2010 Search and eventually work our way up to Microsoft’s latest and greatest FAST Search Server in a near future article.  Before we deep dive into the step by step guide I will begin by listing some of the new features that you will come to expect from SharePoint Server 2010 Search.   These are as follows;
  • Boolean query syntax has finally been introduced.  These include AND, OR and NOT operators in your search queries.
  • Suggestions whilst typing and after running search queries, a feature that we have come to love with major search engines such as Google and Bing.
  • Integrating SharePoint enterprise search with Windows 7, allowing end users to utilise the Windows 7 search box to locate SharePoint 2010 content.
  • Results display has been refined to provide filters for search results such as document type, categories and managed properties.
  • View in Browser capabilities, allows end users to view documents within their own browser utilising Office Web Apps and not having to rely on launching the necessary Microsoft Office Application, or even the need of having it installed on their local machine.  This is handy when browsing your SharePoint site via Kiosks and Internet Cafes that may not be running the Microsoft Office Suite.
  • Last but not least, there have been a number of improvements to People Search, including phonetic name and nickname matching, and improved relevance and self search.
Now that we have a taste for what’s to come, let’s begin our configuration.
SharePoint Server Search is a service application which we have come to learn about over the past few articles that it is independent of other services and is no longer tied to the Shared Services Provider (SSP) that was introduced in SharePoint 2007.
SharePoint 2010 search architecture is made up of the Crawler, Indexing Engine, Query Engine and the User Interface and Query Object Model.  We now have greater flexibility and expandability with our search design in 2010 and can setup not only multiple Query Servers but can now scale out our Index server and add multiple instances.
Below is a logical overview of the components that will make up our SharePoint 2010 search configuration.
image thumb20 Configuring Enterprise Search in SharePoint 2010


Configuring the Service Application
As always we begin our journey in Central Administration / Application Management / Manage Service Applications.
Click New / Search Service Application.
Name: Enter a name for your Service Application.
FAST Service Application: Select “None” (we will leave the configuration of FAST for a future article)


image thumb21 Configuring Enterprise Search in SharePoint 2010


Search Service Account: Click on Register new managed account and ensure your domain account has already 
been provisioned in Active Directory.  I have created a separate search account; e.g. DOMAIN\sp_search


image thumb22 Configuring Enterprise Search in SharePoint 2010


Application Pool for Search Admin Web Service: Create a new application pool for your search admin web service application.


image thumb23 Configuring Enterprise Search in SharePoint 2010


Application Pool for Search Query and Site Settings Web Service: Create a new application pool for your search query web service application.


image thumb24 Configuring Enterprise Search in SharePoint 2010


Click Create
The search service application will begin its configuration process.


image thumb25 Configuring Enterprise Search in SharePoint 2010


You will eventually be presented with confirmation that the search service application was created successfully.
If we now navigate back to Application Management / Manage Service Applications, you will notice that 2 additional services have been added to our list.  These are;
  1. Search Service Application (Typical Search Administration page which is similar to that in SharePoint 2007. From here we can create content crawl rules, reset indexes, setup content sources etc).
  2. WSS_UsageApplication (This is a new service in SharePoint 2010 that specifically handles our Usage and Health Data Collection Service Application.  This service application handles web analytics such as usage, search query usage, rating usage etc  More on this in a future article).
Let’s now launch the Search Administration page by clicking on our Search Service Application.


image thumb26 Configuring Enterprise Search in SharePoint 2010


Our Default content access account should be set to the account that we had specified at the time of provisioning the Search Service Application; i.e. DOMAIN\sp_search


Confirming Permissions
There are a couple of areas to note that we should check to ensure that our Default content access acount (sp_search) has been provided with the appropriate access permissions.  Let’s first begin by checking our User Profile Service Application by Navigating to Service Applications / User Profiles.  Just highlight the User Profiles and select Administrators from the ribbon.


image thumb37 Configuring Enterprise Search in SharePoint 2010


Our newly provisioned sp_search account should have “Retrieve People Data for Search Crawlers” selected as a permission.


image thumb38 Configuring Enterprise Search in SharePoint 2010


We will also confirm that our sp_search account has the necessary “Read” permissions against the Web Applications being crawled.
Navigate to Central Administration / Application Management / Manage Web Applications.  Again, highlight the Web Application in question and from the ribbon select User Policy.


image thumb39 Configuring Enterprise Search in SharePoint 2010


Ensure that the Search Crawling Account is set to the sp_search domain account.


image thumb40 Configuring Enterprise Search in SharePoint 2010


Content Sources
Let’s venture into our content sources listed in the Quick Launch navigation bar under Crawling.
As was the case with SharePoint 2007, our Local SharePoint sites will be detected by default, albeit without a crawl schedule.


image thumb27 Configuring Enterprise Search in SharePoint 2010


Check to see that your Start Addresses are located within your content source via editing the content source from the drop down menu.  These includes all SharePoint Web Applications and the sps3 “User Profiles” address.


image thumb28 Configuring Enterprise Search in SharePoint 2010


You can easily create your crawl schedule by clicking on Local SharePoint sites and scrolling down to Crawl Schedules.


image thumb29 Configuring Enterprise Search in SharePoint 2010


Let’s initiate a Full Crawl by clicking on Start all Crawls from the Manage Content Sources page.
Once your crawl has completed, you should confirm that there were no errors encountered during the initial crawl.  Usually any errors noted are most likely due to incorrect permission assignments.


Creating a “Basic Search Center” Site
If you haven’t done so already, from your top level site, click on Site Actions / New Site.
Select “Basic Search Center”


image thumb30 Configuring Enterprise Search in SharePoint 2010


Enter a Name and URL and click on Create.
This will provision the Search Center similar to the below.


image thumb31 Configuring Enterprise Search in SharePoint 2010


Creating an “Enterprise Search Center” Site
Let’s also create an Enterprise Search Center for comparison.  The key difference here is that we are provided with two tabs for searching, one for Sites and the other for People.  The “Enterprise Search Center” will be the search site of choice for most organizations running SharePoint Server.
From Central Administration / Application Management / Site Collections, click on Create site collections.   Ensure you are creating the Site Collection below the relevant Web Application.
Enter your Title, Description etc and select the Enterprise Tab under Template selection.  Select the Enterprise Search Center, specify your site collection administrators and click OK.


image thumb32 Configuring Enterprise Search in SharePoint 2010


This will provision the Enterprise Search Center similar to the below.


image thumb33 Configuring Enterprise Search in SharePoint 2010


As we have already completed an initial Full crawl earlier, I can now test my new search centers by performing a couple of searches.
Searching Content


image thumb34 Configuring Enterprise Search in SharePoint 2010


Searching People
image thumb35 Configuring Enterprise Search in SharePoint 2010


Now I ran into an issue when trying to search for content located in My Sites.  The crawl log displayed the following warning;
“This item and all items under it will not be crawled because the owner has set the NoCrawl flag to prevent it from being searchable”
In order to fix this issue (and this is true for any Site Collection), is to navigate to your My Site host and click on Site Actions / Site Settings.
Click on “Search and offline availability” under Site Administration, and ensure that you have Indexing Site Content, Allow this site to appear in search results? set to “Yes”.


image thumb36 Configuring Enterprise Search in SharePoint 2010


After enabling the indexing of My Sites, I was able to successfully perform My Site Content searches and the warning disappeared from the Crawl Log.
That’s all that is to it in setting up a search center in its most basic form.  From here you can expand your service applications over multiple servers providing you with redundancy, scalability and increased performance .  Until next time, happy searching :)


References:
TechNet :: Getting Started with Enterprise Search in SharePoint 2010 Products

Aging Calculated Fields in SharePoint


A common question I get and SharePoint challenge is to show the age of something in SharePoint. A typical example is to show the age of a document in days, months, years, etc. Or you might want to keep track of some item (say a coin in a coin collection, or a server in your network). Here we’ll display the age of comic books in a collection in years from the current date. BTW, this isn’t really new as we’ve been doing these tricks for a few years now. I just thought I would share my take on it with the rest of the class.
Setup
First we need a list to keep track of our comic books. Create a new custom list and create a field called “Year Issued”. This should be a numeric field and will be the year the comic book was issued. Add a few entries to the list so you have something like this:
















Notice that the Year Issued shows 1,962 rather than 1962. This is the default behaviour of a number field so you can either a) use a DataView web part and format this later or b) use a text field instead. We only have this problem because we’re trying to capture the year. While there is the Date field, it requires a date to be picked and it’s not quick to enter a year using the calendar control (especially if it’s old) so a text field might be more appropriate for this case, YMMV.

Magic
Now comes the magic. Create a new field called “Today”. Don’t worry about the type, just use the default but make sure you name it “Today” (without the quotes). Then create a new field called “Age” and make it a calculated field. Down in the calculation column, here’s the formula you use:

Notice the use of [Today] in the calculation formula. This is referencing our “placeholder” column we created earlier. Save the calculated column and back at the column list, find the Today column and click on it to edit it. Now in the edit screen, delete it. Yup, get rid of it. We don’t need it anymore.

Now take a look at the list, complete with our calculated field showing us the age of our comic books. Cool huh?

The Secret
Don’t believe the magicians trick that they won’t tell you how they did it. I’m going to. Built into SharePoint are some pre-determined names. [Today] happens to be one of them. For example, if you want a field to have a value of the current date when something is added to a list, just enter [Today] in the default value. This is great, however if you try to use [Today] in a calculated field you’ll get this message:

The secret is to create a placeholder field with same name of [Today]. When the column is validated and saved, it works because it thinks it’s using the column reference you added called [Today] (which you are, at creation of the calculated field). When you removed the column called [Today] the calculated field just used the internal [Today] reference which is that volatile function it couldn’t use before.
You might have noticed after you had the Age column and the placeholder Today column your list might have looked like this:

The calculation isn’t quite right here. That’s because the calculated column was using the existing Today field (a blank field) so the calculation was YEAR([Today])-[Year Issued] which translated to YEAR(0)-1962 and produced –63. YEAR(0) (or YEAR(“”) will result in 1899 as it’s value. Once you removed the blank Today column the calculation used the built-in [Today] value which is the current date and voila!
I know. Silly huh? One note about this “workaround”. If you ever need to edit that calculated field again, you’ll need to create the placeholder [Today] column again, otherwise you won’t be able to save it. Again, just create it, edit your calculated field, then delete it. No harm, no foul.
Variations
There are a lot of variations you can do with this, now that you know the trick. For example, rather than getting the information from the user in a text or numeric field, you can use a date field and then show the age in years, months, and days. Or you can use the built-in creation date compared against the Today trick to show you the age of a document in a document library.
Like I said, this isn’t new and ground shattering. Mark Kruger documented something like this here with a more complicated formula (for displaying the text “Post is X days old”). Chris Johnson has it documented here and Dessie Lunsform has a good post on it here along with links to some calculation formula references.

So be creative, experiment, and have fun!

Developer Dashboard in SharePoint 2010



Do users complain about SharePoint performance? Prior to SharePoint 2010, tracking down performance bottlenecks might involve attaching a debugger to code and enabling a trace from the SQL Server Profiler. Now, with SharePoint 2010, you can use a cool new feature called Developer Dashboard.

Solution

The SharePoint 2010 Developer Dashboard displays tracing and diagnostic information about page rendering and includes information about page components, controls, queries and execution time (an analogy of ASP.NET page tracing).

The Developer Dashboard feature is disabled by default and can be enabled or used on demand either by using STSADM SharePoint Administrative tool or a PowerShell cmdlet or using an API object model. The Unified Logging Service (ULS) logs contain information details about performance issues and resource usage, but analyzing ULS raw data is very difficult and takes time. The Developer Dashboard displays all of this information in a graphical way which makes understanding/troubleshooting quite easier.
The Developer Dashboard works in three different modes.
If you are changing it programmatically, you would use this enumeration : SPDeveloperDashboardLevel), by default it's in OFF mode where it will not capture any tracing information (no debugging information instrumentation).
You can make it capture tracing information On-Demand (allows toggling to capture data or not) or you can put it in ON mode where it will capture all the tracing information all the time. This information is displayed on the bottom of the every page which uses a SharePoint Foundation 2010 master page or a custom master page included with the Dashboard control. You even include Dashboard control on any specific page you want, for detail refer to "Using Developer Dashboard on Custom Master Pages" section on this link.

Enabling/Disabling Developer Dashboard with STSADM

On a SharePoint 2010 installation, STSADM (by default) is in "C:\Program Files\Common Files\Microsoft Shared\web server extensions\14\BIN".

To turn it off (execute either of these two commands)

stsadm -o setproperty -pn developer-dashboard -pv off
stsadm -o setproperty -propertyname developer-dashboard -propertyvalue off

To turn it on demand (execute either of these two commands

stsadm -o setproperty -pn developer-dashboard -pv OnDemand
stsadm -o setproperty -propertyname developer-dashboard -propertyvalue OnDemand

When you enable Developer Dashboard on demand, you will notice a small icon on the top right corner of the page as shown below. Clicking on this icon will put the Developer Dashboard on the bottom section of the page. You can use this icon to toggle ON or OFF the Developer Dashboard.


To turn it on (execute either of these two commands)

stsadm -o setproperty -pn developer-dashboard -pv On
stsadm -o setproperty -propertyname developer-dashboard -propertyvalue On
Once you have enabled the Developer Dashboard, you will see similar information as shown below on your pages. This information includes performance counters which measure usage and resource consumption at the stage of the processing request . For example, Execution start time, Thread execution time, URL of the request, SQL statements generated by the request processing, call stack information about each WCF call, etc.. You can click on the link "Show or hide additional tracing information" shown on left bottom corner to display additional tracing information.


You can hover the mouse over each of the sections and a pop up will display additional information (as below):

Notice that database calls are hyperlinks. Clicking on this link will give you a complete picture about the SQL Command executed, the numbers of parameters passed and returned, IO stats from SQL and the call stack as you can see below:

SharePoint 2010 installation and options

Scenario:
Now with so many different hardware and software's in market there is a big permutation and combination possible on how to install Share Point 2010.

Here's a few which you can choose from and also leave a comment if you know any more...

Hyper-V Virtualization
-- Good with 6 GB RAM or more.You need to have processors with 64 bit and guest 64bit virtualization support.

1. HOST - Windows Server 2008 R2 Enterprise ( Enterprise edition supports Hyper-V )
GUEST - Windows Server 2008 R2 Standard with SP2010 farm installation

2. HOST - Window Server 2008 R2 Enterprise ( Enterprise edition supports Hyper-V )
GUEST - Windows 7 Ultimate N with Standalone installation of SP 2010 only

3. HOST - Window Server 2008 R2 Enterprise ( Enterprise edition supports Hyper-V )
GUEST - Windows Vista Ultimate with Standalone Installation

VM Ware / Virtual Box
-- Good with 6 GB RAM or more.You need to have processors with 64 bit and guest 64bit virtualization support.

1. HOST - Windows Server 2008 R2 Standard with VMWare or Virtual Box
GUEST - Windows Server 2008 R2 Standard with SP2010 farm installation

2. HOST - Windows 7 with VMWare or Virtual Box
GUEST - Windows Server 2008 R2 Standard with SP2010 farm installation

3. HOST - Windows Vista with VMWare or Virtual Box
GUEST - Windows Server 2008 R2 Standard with SP2010 farm installation

Dual Boot / Boot from VHD option
-- Good with 4 GB RAM or more.You need to have processors with 64 bit and virtualization support.

1. HOST - Windows Server 2008 R2 Standard
DUAL BOOT - Windows Server 2008 R2 Standard with SP2010

2. HOST - Windows 7 Ultimate N
DUAL BOOT - Windows Server 2008 R2 Standard with SP2010

3. HOST - Windows Vista Ultimate
DUAL BOOT - Windows Server 2008 R2 Standard with SP2010

Developer workstation installation option

1. HOST - Windows Vista Ultimate N with Standalone SharePoint 2010 Installation

2. HOST - Windows 7 Ultimate N with Standalone SharePoint 2010 Installation

Also as there are multiple option available for installing Windows Server 2008 R2 , Please notice that in most cases you need 1st or 3rd one for Development Environments.

wi edit
Articles:
MSDN