SharePoint 2013 – Could not connect to Search HostController error

When i try to move the Search crawler and other component to different server i got this error. The below powershell command solved the issue $acl = Get-Acl HKLM:\System\CurrentControlSet\Control\ComputerName        $person = [System.Security.Principal.NTAccount] “Users” $access = [System.Security.AccessControl.RegistryRights]::FullControl $inheritance = [System.Security.AccessControl.InheritanceFlags] “ContainerInherit, ObjectInherit” $propagation = [System.Security.AccessControl.PropagationFlags]::None         $type = [System.Security.AccessControl.AccessControlType]::Allow         $rule = New-Object System.Security.AccessControl.RegistryAccessRule($person, $access, $inheritance, $propagation, $type)         $acl.AddAccessRule($rule)         Set-Acl HKLM:\System\CurrentControlSet\Control\ComputerName $acl $sh = Get-SPServiceInstance | ? {$_.TypeName -eq “Search Host Controller Service”} $sh.Unprovision()         $sh.Provision($true)     Source http://mmman.itgroove.net/2012/12/search-host-controller-service-in-starting-state-sharepoint-2013-8/ Thanks     Deleted any photos? Easily fix it using this Product Advertisements Continue reading SharePoint 2013 – Could not connect to Search HostController error

Failed to connect to hosts in the cluster – SharePoint 2013

Recently got this error when i try to run the PS command to stop the Distributed cache stop-spdistributedcacheserviceinstance   Eventually it happened because the “Remote Registry” service under the Services was not started in the App server. I started the service then i could able to execute the above command.   Fix your Microsoft Access Issue easily using this Product Continue reading Failed to connect to hosts in the cluster – SharePoint 2013

How to find Concurrent Users for SharePoint and ASP.NET using IIS Logs

This post is about finding the number of concurrent users. The concurrent users helps to do the capacity planning for SharePoint. Below are the main attributes required to do the capacity planning for SharePoint 2010/2013. Average daily RPS Average RPS at peak time Total number of unique users per day Average daily concurrent users Peak concurrent users at peak time Total number of requests per day   One of the main attribute for the planning is the Concurrent users. Below are the steps required to find the concurrent users Enable the IIS Logs in the server Collect the logs for … Continue reading How to find Concurrent Users for SharePoint and ASP.NET using IIS Logs

Enable Search Charm Settings For Windows 8 App

This blog discuss on how to enable Search Charm settings and direct the search query to the custom Search Xaml Page. Below are the steps needs to be done to enable search Enable Search Contract in VS 2012 Create SearchPage.Xaml for the search result Add the code to the SearchPage.Xaml to search and show the result. Modify App.Xaml.cs to enable Search and query submit event.   Step 1:Enable Search Contract in VS 2012 In the Visual Studio 2012 open the App project. Once the project is loaded locate the file “Package.appxmanifest” and open it by double click on it. On … Continue reading Enable Search Charm Settings For Windows 8 App

wCF RIA Service to return simple types except IQuerable

WCF RIA Domain service will always return the IQuerable tyoe not the primitive types like int, or List. In some cases it is eminent that we need to just return the ID field which is int or List<string> customerList to the client not the whole table. The below sample will explain how to do it.   Step 1: Create the domain service by right click on the web project of the RIA Service and select New Item and select the Domain Service from the List   Step 2: Name the domain service to relevant table name in my case “CustomerService.cs”. … Continue reading wCF RIA Service to return simple types except IQuerable

Calling WCF RIA Service from Code behind

Assume that there is a RIA Service usually under ProjectName.Web and inside the Service folder with the file name ArtifactService.cs and with the below implementation   namespace ProjectName.Web.Services {     using System;     using System.Collections.Generic;     using System.ComponentModel;     using System.ComponentModel.DataAnnotations;     using System.Data;     using System.Linq;     using System.ServiceModel.DomainServices.EntityFramework;     using System.ServiceModel.DomainServices.Hosting;     using System.ServiceModel.DomainServices.Server;     using ProjectName.Web.Models;     [EnableClientAccess()]     public class ArtifactService : LinqToEntitiesDomainService<PROJEntities>     {         public IQueryable<Artifact> GetArtifacts()         {             return this.ObjectContext.Artifacts;         }         public IQueryable<Artifact> GetArtifactById(string projectId)         {             if (!string.IsNullOrEmpty(projectId))             {                 Guid filterValue = Guid.Parse(projectId);                 return this.ObjectContext.Artifacts.Where(i … Continue reading Calling WCF RIA Service from Code behind

Datagrid cell coloring and Header Style Wrapping using XAML

Sometime there is a need to change the Datagrid header text to wrap and change the width and the style. The below sample will discuss about the coloring and changing the header style   The full source is available here in the SkyDrive   Preview of the code   XAML: First the Styles needed for the Cell   <Style x:Key="dataGridHeaderStyle" TargetType="dataprimitives:DataGridColumnHeader">             <Setter Property="ContentTemplate">                 <Setter.Value>                     <DataTemplate>                         <TextBlock Text="{Binding}" TextWrapping="Wrap" TextAlignment="Center" />                     </DataTemplate>                 </Setter.Value>             </Setter>         </Style>         <Style x:Key="RAGCellBorderStyle" TargetType="Border">             <Setter Property="HorizontalAlignment" Value="Stretch" />             <Setter Property="VerticalAlignment" Value="Stretch" />             <Setter Property="BorderThickness" Value="1,1,1,1"/> … Continue reading Datagrid cell coloring and Header Style Wrapping using XAML

Colour converter based on Status string.

Declare a class and inherit from the IValueConverter using System; using System.Net; using System.Windows; using System.Windows.Controls; using System.Windows.Documents; using System.Windows.Ink; using System.Windows.Input; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Shapes; using System.Windows.Data; public class StatusColorConverter:IValueConverter { public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) { string status = (string)value; if (value == null) { return new SolidColorBrush(Colors.LightGray); } if (string.IsNullOrEmpty(status)) { return new SolidColorBrush(Colors.LightGray); } else if (status.Trim() == "Open") { return new SolidColorBrush(Colors.Orange); } else if (status.Trim() == "Closed") { return new SolidColorBrush(Colors.Green); } else { return new SolidColorBrush(Colors.LightGray); } } public object ConvertBack(object value, Type targetType, object parameter, … Continue reading Colour converter based on Status string.

Multiple Silverlight Application to Web Application

Visual Studio 2010 allows to add multiple Silverlight Projects to the Solution. These silverlight projects can be added to the single web application project. To add multiple Silverlight Project to the Web Application, select the Web Application and right click and go to Properties   In the properties page there will be a Silverlight Application Tab. Click on the Add button to select the SIlverlight Project Continue reading Multiple Silverlight Application to Web Application