Probably the most simple way to hide View header would be to use CSS

1 Add Content Editor web part on View page (located under Media & Content category)

2 Insert the following code into CEWP

<style type="text/css">

.ms-viewheadertr { display:none; }


When you use the "Promoted Links" web part on one of your pages, there is the possibility that the web part uses a lot of horizontal space, because you need to display a large number of tiles; for example, 12 tiles. For an aesthetically-pleasing display of the tiles, without cumbersome scroll buttons, you would need a large 16:9 monitor.

So wouldn’t it be nice to have the option to cause the tiles to "wrap?" An example of useful wrapping would be breaking up the 12 tiles into 3 rows; 1 row for each 4 tiles. This would create the desired aesthetically pleasing display, without going past the edge of smaller screens. With this small JavaScript,the proper wrapping of tiles is possible.
Just add a "Script Editor" web part to the page and paste the following code to the snippet.

<script type="text/javascript" src=" "></script>

<script type="text/javascript">

$(document).ready(function () {

// Update this value to the number of links you want to show per row

var numberOfLinksPerRow = 4;

// local variables

var pre = "<tr><td><div class='ms-promlink-body' id='promlink_row_";

var post = "'></div></td></tr>";

var numberOfLinksInCurrentRow = numberOfLinksPerRow;

var currentRow = 1

// find the number of promoted links we're displaying

var numberOfPromotedLinks = $('.ms-promlink-body > .ms-tileview-tile-root').length;

// if we have more links then we want in a row, let's continue

if (numberOfPromotedLinks > numberOfLinksPerRow) {

// we don't need the header anymore, no cycling through links

$('.ms-promlink-root > .ms-promlink-header').empty();

// let's iterate through all the links after the maximum displayed link

for (i = numberOfLinksPerRow + 1; i <= numberOfPromotedLinks; i++) {

// if we're reached the maximum number of links to show per row, add a new row

// this happens the first time, with the values set initially

if (numberOfLinksInCurrentRow == numberOfLinksPerRow) {

// i just want the 2nd row to


// create a new row of links

$('.ms-promlink-root > table > tbody:last').append(pre + currentRow + post);

// reset the number of links for the current row

numberOfLinksInCurrentRow = 0 }
// move the Nth (numberOfLinksPerRow + 1) div to the current table row$('#promlink_row_' + currentRow).append($('.ms-promlink-body > .ms-tileview-tile-root:eq(' + (numberOfLinksPerRow) + ')'));

// increment the number of links in the current row

numberOfLinksInCurrentRow++; }




Note that this script also adds a reference to the jQuerylibrary. When you already have access to jQueryon your SharePoint site you can delete the first row.

After saving your edited page it should look like this:

With the variable "numberOfLinksPerRow" you can control the count of tiles per row.

Reference :

SharePoint Broken URL Fix

Posted: March 25, 2015 in SharePoint

SharePoint Broken URL Fix

Often users ends up in a mess trying to change logo or descriptions it playing with site settings and ends up breaking their sub site URL. I often receives such issues from end users and here is the PowerShell script that I use to fix this:

In this case, user accidentally renamed a subsite called Demo to Demo.aspx http://<server name>/SITES/RootSite/Demo.aspx

Set-SPWeb -Identity http://<server name>/SITES/RootSite/ Demo.aspx/ -RelativeURL Demo

Hope this helps J

SharePoint Date Formulaes

Posted: March 24, 2015 in SharePoint

Note : I have referenced Created field in these formulas, you will need to change as per your requirements





To get Quarter from Date Field

=IF(MONTH(Created)<=3,Concatenate("Q1-",TEXT(Created,”yyyy")), IF(MONTH(Created)<=6,Concatenate("Q2-",TEXT(Created,”yyyy")), IF(MONTH(Created)<=9,Concatenate("Q3-",TEXT(Created,”yyyy")),IF(MONTH(Created)<=12,Concatenate("Q4-",TEXT(Created,”yyyy")),""))))

To Get Month from Date Field


Reprovision User Profile Sync Service

If you find yourself in a situation where you’ve exhausted normal efforts in fixing miscellaneous User Profile Synchronization (UPS) issues, a good final resort attempt can be done by following the below steps to reprovision UPS:

· Backup the User Profile DB and the User Profile Sync DB on your SharePoint SQL DB server (this is for ‘just in case’ something should go wrong in the following steps so you can restore the DB’s)

· Log on to your SharePoint App server with Farm account

· Stop the SharePoint 2010 Timer service:

o Stop SharePoint 2010 Timer from Services in Server Manager or ‘net stop sptimerv4’ from command line

Delete the data in the Sync DB using the following PowerShell commands:

· Open SharePoint 2010 Management Shell as administrator

· Type in ‘Get-SPDatabase

o Copy the GUID associated with the User Profile Sync DB

· Type in ‘$syncdb=Get-SPDatabase –ID[paste
GUID of UPS Sync DB]

· Type in following in order, executing one by one:

o $syncdb.Unprovision()

o $syncdb.Status=’Offline’

o Get-SPServiceApplication

§ Now locate and copy the GUID associated with the UPS to use in next command

· $ups=Get-SPServiceApplication –ID[paste
GUID from above]

· $ups.ResetSynchronizationMachine()

· $ups.ResetSynchronizationDatabase()

· $syncdb.Provision()

· On the SharePoint SQL DB Server via SQL Studio Manager, add the UPS service account (farm account) as the DBOWNER on the Sync DB

· Start the SharePoint 2010 Timer service in Server Manager or ‘net start sptimerv4’ from command line

· Start the User Profile Synchronization Service in Central Admin

· After User Profile Synchronization Service is started (may take up to 10-20 mins), do a ‘iisreset/noforce’ on your SharePoint servers

· From Central Admin, go into Manage Service Applications, click an open your User Profile Service service application.

· Under Synchronization, click on Configure Synchronization Connections and create your data sync connection (AD)

· Once the connection is created, if you had any Connection Filters (such as Disabled Users), you will need to recreate them by clicking on the drop down next to your connection and select ‘Edit Connection Filters’. From experience, you may want to check the existing filters prior to performing this entire process to make sure you know what filters exist, as they will be wiped out once your start the above PowerShell sequence.
NOTE: If you also had any Property Mapping for Synchronization mappings setup (such as exporting users Picture (thumbnailPhoto) into Active Directory), you will need to set these back up as well.

· After completed, proceed with running a Full User Profile Synchronization

As always, use the above provided instructions and PowerShell at your own risk, as every situation and SharePoint farm environment can differ.

$WebApplication = Get-SPWeb http://<SiteCollectionName>

$List = $WebApplication.Lists["List Name"]

$List.EnableThrottling = $false


Powershell Error : Get-SPSolution..The local farm is not accessible.

For a relatively new user who’s just added to the farm, even if the user is a Farm Admin, receives one of the following errors especially when deploying a WSP:

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

followed by this error

"Get-SPSolution : Cannot access the local farm. Verify that the local farm is pr
operly configured, currently available, and that you have the appropriate permissions to access the database before trying again."


1. Login as the Farm Setup user
2. Launch SP2010 Managementshell
3. Run ADD-SPSHELLADMIN -USERNAME domain\UsertobeAdmin