Tuesday, July 10, 2012

Replace Delegate Control – SmallSearchInputBox

I've got a task to change the OOTB SharePoint search box control and I found this links is useful to customize it and prevent the search results keyword from "This site scope"

http://sharepointroot.com/2011/05/25/replace-sharepoint-delegate-control-smallsearchinputbox/

First step is to register the search box assembly to the master page files.

<%@ Register Tagprefix="SharePointWebControls" Namespace="Microsoft.SharePoint.Portal.WebControls" Assembly="Microsoft.Office.Server.Search, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %>

Then Replace SharePoint controls search box which is the syntax like this
SmallSearchInputBox" Version="4"/>

With this one


The search box property can be found on MSDN reference link here

Hope this helps,
PJ

Monday, July 2, 2012

The SharePoint item being crawled returned an error when requesting data from the web service.

When using FAST search for SharePoint 2010 (F4SP) to crawl a content source that contains managed metadata in the field you might get this error

The SharePoint item being crawled returned an error when requesting data from the web service. ( Error from SharePoint site: *** Index was outside the bounds of the array. )

this is because one or more metadata field is filled with incorrect value. When you open it up it show something like this.



The red underline text means there's no term "Knowledge" in the Knowledge Themes metadata field.
if you leave this red text save in your item properties and run a crawling. You will get this error.

To solve this error
That's simple, correct the red underlined text in metadata field. then FAST search will crawl this item correctly.

Tuesday, May 29, 2012

Make connection string from web.config

in your web application you can add the below line to read data configuration in web.config file

DataClassesDataContext lu = new DataClassesDataContext(System.Configuration.ConfigurationManager.ConnectionStrings["LikeWebPartDataConnection"].ConnectionString);

and add below line in appSettings section in web.config files
   

Wednesday, May 9, 2012

Enable Fast Search feature on SharePoint Publishing Site

Refer to
http://social.technet.microsoft.com/Forums/en-US/fastsharepoint/thread/d83894e3-fc7c-40e4-99ab-7ac1a5392265

I got the solution to enable FAST search site template for Publishing site with just one command

Enable-SPFeature –Id SearchExtensions –url


Hope this helps

Thursday, April 19, 2012

Clear-FASTSearchContentCollection : Failed to communicate with the WCF service.

According to this title error when clear fast search index using PowerShell command.
Clear-FASTSearchContentCollection -Name sp
and I got this error
Failed to communicate with the WCF service.
then i changed user account to run this command by Shift + Right Click on FAST Search

Then log on as FAST service account to run this command instead of current account.


Hope this helps.