Cloud4MEA … All about cloud


Heads up, we are here finally!
‪#‎Cloud4MEA‬ is the first Arabic channel specialized in cloud computing services
All high quality educational content for all our followers in MEA for free
Watch our tutorials, latest news about cloud, ‪#‎Microsoft‬ ‪#‎Office365‬and more
Subscribe to our channel on YouTube, follow us in twitter and Facebook

#Microsoft #Office365 ‪#‎Cloud‬ #Cloud4MEA

Advertisements

SharePoint Calendar: Specified argument was out of the range of valid values [Exception]


I had a very weird issue when opening a SharePoint calendar

Specified argument was out of the range of valid values [exception]

error

My first doubt was invalid values have been entered by a user at the start or end dates however, i wasn’t able to open the calendar list to check.

I found online that when i add this string to the calendar URL

?CalendarDate=10/10/2011&CalendarPeriod=week” it will open!

Then i found a record like so

Screenshot_1

A user types in End Date year value 9999

By deleting this record everything went fine and calendar now is working properly.

I hope this bite helps you guys

SharePoint 2013 Change Master Page Search Box Watermark Text Value


If you are using SharePoint server 2013 in creating multi-language website, it is highly recommended to use SharePoint variation feature, which allows you to create multi labels for your website. Each label will show different content and regional settings based on required languages.

When it comes to master page customization, many of us struggling in changing some content like; search box watermark text like in picture below:

search En

Here below very simple steps to change this watermark value:

  • Open master page in “Advanced Mode” using SharePoint Designer 2013
  • Search for “SearchWC:SearchBoxScriptWebPart
  • Add the following property with the required value to the “SearchWC” control  InitialPrompt=”بحث…”

Then the result will be as below:

search Ar

Enjoy this bite!

How to Create a SharePoint Site Collection with a Separate Content Database Using PowerShell ISE


Microsoft SharePoint server is having some boundaries and limits in some areas, to read more about these limits please check this article at technet.

In this article let’s focus on web application and site collection limits. When you create a new web application, SharePoint will create a new content database to contain all information about this web application and any site collection under its shield. SharePoint supports 200 GB for every content database which includes the created web application and its babies (site collections and sub-sites).

In many scenarios you will be required to create a site collection for document management purposes, which means more data size to be stored. In this case, creating a site collection with a separate content database is highly recommended approach to achieve this.

Let’s see how to create a SharePoint site collection with a separate content database using a very handy Windows server tool: PowerShell ISE

  • Step 1 – Create a new web application using SharePoint central administration
  • Step 2 – Check created content database

In this step all what you need is to open central administration then from “Application Management” section select “Manage content databases”. Select the web application to show all available content database for this web application, you can notice that by default it contains only one content database for everything.

Content databases

  • Step 3 – Open PowerShell ISE to create the script

In this step which considered the main one, we will see how to manage the whole process from PowerShell ISE console.

To open it, just type the name at start screen and select “Windows PowerShell ISE”  as administrator, DON’T use (x86) version.

ISE

First part of the script will show the required variables we need to set for the process as follow

#this line is to reference Microsoft SharePoint PowerShell namespace
#to be able to use SharePoint commands
Add-PSSnapIn Microsoft.SharePoint.PowerShell -ErrorAction SilentlyContinue;
#Create command required variables
$siteName = "DMS";
$webAppUrl = "http://intranet.vlabs.local";
#You can select any site collection template code by typing Get-SPWebTemplate
$template = "STS#0";

$ownerAlias = "vlabs\ahmed.moussa";
$secondaryOwnerAlias = "vlabs\ayman.hattab";

#this variable is considering that you have a wildcard manged path "departments"
$siteUrl = "$webAppUrl/departments/$siteName";
$databaseName = "WSS_Content_$siteName";
$databaseServer = "SP2013.vlabs.local";

Second part is to create a new content database inside the selected web application to be assigned to the new site collection

 

#Create new content database for DMS department site collection
New-SPContentDatabase -Name $databaseName -DatabaseServer $databaseServer -WebApplication $webAppUrl;

Then Create the site collection and pass the content database to it as follow

#Create new site collection for DMS department
New-SPSite -Url $siteUrl -OwnerAlias $ownerAlias -SecondaryOwnerAlias $secondaryOwnerAlias -ContentDatabase $databaseName -Template $template -Name $siteName;

Last step is to create the security groups of the new site collection because SharePoint doesn’t create them by default.

#New-SPSite doesn't create default SharePoint security groups
#Create DMS site collection default groups
$web = Get-SPWeb $siteUrl;
# this symbol i:0#.w is presenting windows authentication security mechanism
$web.CreateDefaultAssociatedGroups("i:0#.w|$ownerAlias","i:0#.w|$secondaryOwnerAlias",$siteName);
$web.Update();</pre>
<pre>
  • Step 4 – Navigate to manage content databases

Now you have a new content database (200 GB) limit for the new site collection in your web application.

Enjoy this bite!