Thursday, August 28, 2014

The file or folder name contains characters that are not permitted. Please use a different name.

The file or folder name contains characters that are not permitted. Please use a different name.

When you try to create a folder name or list in SharePoint you might have come across this error.The reason is that there are some restrictions on the characters that you cannot use in site names, folder names, and file names in SharePoint.



Site names, subsite names, or site group names
You cannot use the following characters anywhere in a site name, in a subsite name, or in a site or Active Directory group name:
- Tilde (~)
- Number sign (#)
- Percent (%)
- Ampersand (&)
- Asterisk (*)
- Braces ({ })
- Backslash (\)
- Colon (:)
- Angle brackets (< >)
- Question mark (?)
- Slash (/)
- Plus sign (+)
- Pipe (|)
- Quotation mark (")

You cannot use the above characters anywhere in a folder name or a server name or in a file name
More details on this can be found at Reference

Tuesday, August 26, 2014

The local farm is not accessible. Cmdlets with FeatureDependencyId are not registered

Issue

SharePoint Management shell was giving errors : The local farm is not accessible. Cmdlets with FeatureDependencyId are not registered

Cause

The below software were installed and this caused a compatibility issue with SharePoint.

Microsoft .NET Framework 4 Extended                   4.0.30319
Microsoft .NET Framework 4 Client Profile               4.0.30319

Resolution

Uninstalled the above software from the SharePoint servers.

Friday, August 22, 2014

Difference between Integrated Security = True or SSPI

Guys,

I am pretty sure that when we work with connection strings we would have come across this multiple times. 

"Persist Security Info=False;Integrated Security=true;Initial Catalog=Northwind;server=(local)"

Below is an explanation:

Integrated Security -or- Trusted_Connection (Default value = 'false')

1. When false, User ID and Password are specified in the connection.

2. When true, the current Windows account credentials are used for authentication.

3. Recognized values are true, false, yes, no, and sspi (strongly recommended), which is equivalent to true.

4. If User ID and Password are specified and Integrated Security is set to true, the User ID and Password will be ignored and Integrated Security will be used.



Exception - With an OLE DB (non SQL) connection:

1. Integrated Security is not equivalent to Trusted_Security.

2. TRUE and YES are not the same as SSPI.


To use Windows authentication with OLE DB, one must use "Integrated Security=SSPI". 
Using TRUE or YES for this value does not work. 
Using Trusted_Connection with any value does not work.

Difference between ODBC and OLE DB data sources

In this post I want to explain the difference between ODBC and OLE DB.This is what I found based on my reading on the web and my understanding.

1) ODBC provides access only to relational databases

2) OLE DB provides the following features:
a) Access to data regardless of its format or location
b) Full access to ODBC data sources and ODBC drivers

In simple words, ODBC is used only for SQL based data sources whereas OLE DB is used for both SQL and non SQL data sources.I have put in a diagram also below. That might explain it better.


Connection strings for Analysis Services (SSAS) or OLAP

When you work with SharePoint and you want to establish connection with Analysis Services (SSAS) or Cubes you would need to generate connection strings to connect to the Data Source. Some sample connection strings are below: 

Standard

Data Source=myServerAddress;Catalog=myDataBase;

Encrypted Connection
This one authenticates the user and encrypts the communication. This is the highest level of security.

Data Source=myServerAddress;Catalog=myDataBase;ProtectionLevel=PktPrivacy;

Signed Connection
This one authenticates the user and prevents the content in the communication to be modified.

Data Source=myServerAddress;Catalog=myDataBase;ProtectionLevel=PktIntegrity;

Authenticated Connection
This one authenticates the user but does not secure the communication.

Data Source=myServerAddress;Catalog=myDataBase;ProtectionLevel=Connect;




Tuesday, August 5, 2014

Hiding SharePoint Search Center Title and Description

1. Browse to the Page -> Edit Page -> Add Web Part -> Media and Content -> Content Editor -> Click here to add content -> On the ribbon -> HTML -> Edit HTML Source

2. Paste the below code :

<style>
.s4-mini-header {
            VISIBILITY: hidden
}</style><style>
.s4-mini-titlesep {
            VISIBILITY: hidden
}</style>


3. Content Editor Web Part ->Edit Web Part properties -> Appearance -> Chrome Type -> None


4. Page -> Publish 

Downloading/Extracting WSP (Solution) from SharePoint

Background
Last week I was working on a SharePoint project where I had to get all the wsp’s deployed in the farm and I was not able to find few .wsp files anywhere in the Central Administration server. In the Central Administration Solution Properties screen, there is an option to Retract the solution but no option to Download the solution

Solution
I am not sure if there is a way to do this using stsadm. But definitely we can do this using SharePoint PowerShell.To run this command, you need to be a member of the Farm Administrators group and have permission to the configuration database

$farm = Get-SPFarm
$file = $farm.Solutions.Item("deployedsolutionname.wsp").SolutionFile
$file.SaveAs("c:\temp\deployedsolutionname.wsp")

Hiding Title Column in a SharePoint list

1. Navigate to the SharePoint list page that contains the Title data you want to hide.

2. Go to the Settings menu at the top of the page and select List Settings.

3. Click on the link labeled Advanced Settings.

4. Select the Yes radio button next to Allow the Management of Content Types. Then click OK.



5. Click on Item from the Content Types section of the page.



6. Click on the item labeled Title.



7. Scroll down to the Column Settings section and choose the Hidden radio button.



8. Click OK to save the settings.