Showing posts with label Sharepoint 2013. Show all posts
Showing posts with label Sharepoint 2013. Show all posts

Thursday, January 2, 2014

Print to PDF option for SharePoint 2013 documents

From SharePoint 2013 by adding OWA we can get many add-ons. Few of them are Document previewing documents on hover and print PDF etc. Document preview allows users to view the documents and read entire document.

Print PDF will allow users to print the document as in PDF. We can locate the menu and select the option to print PDF.

To locate print PDF option, navigate to library or the WebPart where we are storing the documents. Select the document and click on “…” to the right side of the document. Click on menu on the bottom right.


We have the options to download a copy and Print PDF as shown below. Select “Print to PDF” option to print document as PDF.


We can see the window with link in the office web app. Click on the link to view the pdf.



We can cancel the printing options depending on the access additional options like download or zoom. We can see this option by adding OWA features to SharePoint.

Thursday, December 26, 2013

Map crawled property to a managed property in SharePoint search

In SharePoint search, we can map crawled properties with managed properties. We can map the properties by using the steps below,

Navigate to Site settings page in SharePoint site collection and click on Search schema in Site collection Administration section.


In Site Collection Administration – Managed Properties page, enter the Managed property name in Managed property text box to search. Select the property, click on Edit/Map property option.



In Edit Managed Property page, “Mappings to crawled properties” section, select “Include Content from all crawled properties” option and click on “Add a Mapping” button.



In crawled property section dialog box, Search for a crawled property name field, enter the property name and click on “Find” button to search for the property.



We can the properties in “Select a crawled property” box. Select the properties and click on OK to save the settings.

Friday, December 20, 2013

“The maximum number of allowed sessions per user has been exceeded. This operation cannot be completed” Error in SharePoint Excel services

While working with SharePoint Excel chart and graphs I got an error saying that “The maximum number of allowed sessions per user has been exceeded. This operation cannot be completed” as shown the image below.


We can get this error maximum sessions limit exceeded. By increasing the Maximum Session Per user limit, we can fix this error. We can increase the Maximum Sessions Per User by using the steps below,

Navigate to Application Management page and click on Manage Service Application link in Service Applications section. 



Click on Excel Service application in the list of service applications



 In Manage Excel Services Application page, click on “Global Settings” link






In Excel Services Application Settings page, “Session Management” section, enter Maximum sessions Per User. By default it is 25.  


Thursday, December 19, 2013

Configure custom search result type in SharePoint site collection

Search result type is a rule that displays the search results in different ways. It will consist conditions that compare the search results. It also consists display template to use search results to meet the conditions.
To configure custom search result type we have to follow the steps below,
Navigate to Site Settings page, click on Search Result types in Site Collection Administration section.


Click on New Result Type to create new result type in Manage Result Types page.



We’ll navigate to Add Result Type page. In Add Result Type page Enter the name in “Give it a name” text box in General Information Section.








In Conditions section, we can specify source in “Which source should results match?” drop down. In What types of content should match? You can skip this rule to match all content” drop down allows us to specify the matched content. Here we have options to add more values by clicking on “Add Value” link.



In “Show more conditions” section, we can specify we can specify conditions for the search by specifying the values in “Which custom properties should match?” section.



In “Actions” section, “What Should these result look like” dropdown we can select display type. By checking “Optimize for frequent use” check box to appear the results frequently in search results.


Wednesday, December 18, 2013

Import query suggestions in SharePoint search

In SharePoint search query suggestion allows users to enter the search terms easily by appearing the suggestion words under the search box. SharePoint automatically create the suggestions depending on the previous search history. We can create query spelling suggestions manually by exporting the query suggestions file.

We can create query suggestions by creating the new text file and adding the query spellings one word per a line.


Save the text file as .txt with UTF-8 encoding format.



To import query suggestions file in SharePoint site Navigate to Search Administration page in SharePoint central Administration (Application Management -> Manage Service Applications -> Search Service Application) and click on “Query Suggestions” link in quick launch Queries and Results section.


In Query Suggestion Settings page, , Select “Show search suggestions” check box and Select “Language for suggestion phrases” section select Language as “English”. In Always suggest phrases section click on “Import from text file” link to upload the text file. 



In “Import phrases for query suggestions” page, Text file with phrases section click on browse button to browse and add query suggestion text file created earlier, click on ok to save the settings. 



Sunday, December 15, 2013

Correlation Tokens in SharePoint workflow

Correlation tokens are unique identifiers in SharePoint that bridges to map the objects between the workflow and windows workflow environment. Windows workflow acts as a intermediate layer to communicate with other software. When incoming request arrives, runtime receives the request and determines the request and identifies the workflow instance. Then it process the request for the instance.

Windows workflow acts as a communication channel for all the workflow instances. We can have two separate correlation tokens for Workflows and task references. We cannot assign the correlation token to workflow task that used for workflow.

We have to declare the correlation token for the workflow in OnWorkflowActivated activity. We have to bind the this correlation token to  each activity in the workflow.
OnWorkflowActivated activity raises when workflow initiated  for SharePoint. This is the first event raised in workflow. Each task should have its own correlation token that provides the task related information. 

Tuesday, December 10, 2013

ViewFormPagesLockDown feature in SharePoint

In General by enabling the anonymous access in SharePoint site, anonymous users will have read-only access to the site. But when we enable anonymous access to SharePoint publishing site, we can have issues with anonymous users in SharePoint site due to ViewFormPagesLockDown feature. This feature will block users to view list view pages. Users can able to access all other web pages. Generally we can face this issue whenever users wanted to comment a blog post as anonymous in SharePoint blog site located in SharePoint publishing site collection.

We can check the ViewFormPagesLockDown feature is active or not by using following Power Shell command.

get-spfeature –site SiteURL


Here SiteURL is URL of the Site to check ViewFormPagesLockDown feature is active. By entering this command we can the list of features that are active in SharePoint site.
By disabling ViewFormPagesLockDown feature we can set anonymous users to access list view pages. to disable that we have to run following PowerShell commands

$lockdownFeature = get-spfeature viewformpageslockdown
disable-spfeature $lockdownFeature SiteURL



here SiteURL is URL of the site to disable ViewFormPagesLockDown feature. By disabling this feature anonymous users can access list view pages as usually.

Monday, December 9, 2013

Configure Web Part page security in SharePoint

In SharePoint webparts are the reusable sections in a SharePoint web page. We can add the functionality to SharePoint site by customizing webparts. We can connect the links to one WebPart to another WebPart by using WebPart connections.

We can manage the security of webparts from SharePoint central administration. To manage the security, Navigate to Security section in SharePoint central Administration, Click on Manage Web Part security link in General security section.


Select web application in Security for Web Part Pages page, Web Application section. In “Web Part Connections” section, we can specify the users to allow the connections by passing data or values from a source Web Part to target Web Part. By Selecting “Allow users to create connections between Web Parts” option we can allow people to create the connection. By Selecting “Prevents users from creating connections between Web Parts, and helps to improve security and performance”

In Online Web Part Gallery section, we can specify users to access the online Web Part gallery. By Selecting “Allow users to access the online Web Part Gallery” option we can allow users to access the online WebPart.

We can allow the scriptable webparts by specifying “allow contributors to add or edit scriptable Web Parts” option in Scriptable Web Parts section. Click on Ok to save the settings


Thursday, December 5, 2013

Content Iterator in SharePoint

In SharePoint object model while getting the data from large lists through SPQuery, we can get SPQueryThrottleException saying that “The attempted operation is prohibited because it exceeds the list view threshold enforced by the administrator”. We can get rid of this exception by using Content Iterator (CI). Content Iterator provides implementation interface for SharePoint objects to regularize the amount of data to be transferred. This will helps queries in on the lists to not put the load on database excessively. It will iterate the content in the list instead of executing the query. So that it will process each item in the list to avoid the throttling limits.

We can process the content iterator to crawl the list items. Following is the sample code will give us the detail about Content Iterator processing

public static void ProcessListItems(SPWeb site)
{ 
string iteratorName = "item iterator"; 
ContentIterator iterator = new ContentIterator(iteratorName);

iterator.ProcessLists(site.Lists,
delegate(SPList list){ 
ContentIterator.EnsureFieldIndexed(list, list.Fields.GetFieldByInternalName("Title").Id);
string query = "<Where><And><BeginsWith><FieldRef Name='Title' /><Value Type='Text'></Value>RT</BeginsWith></And></Where>"; 
ContentIterator itemsIterator = new ContentIterator(iterator);
itemsIterator.ProcessListItems(list,query,true,
delegate(SPListItemCollection items){
foreach (SPListItem item in items){
ProcessItem(item);
}
},null);
},
delegate(SPList list, Exception e)
{
OnListException(list, e);
});
}



Wednesday, December 4, 2013

Retention stages for SharePoint 2013 Document library

In SharePoint Document library retention policies we can set the retention policy for Content type and library document and folders. By applying the retention policies to document library items we can make them delete or make them records with the existing options.

To set the retention policies for library items or folder we have to navigate library settings page and click on Information management policy settings link in Permissions and Management section.


In Information Management Policy Settings page click on Change Source link in Source of retention for this library.



Select Library and Folders option in “Source of Reflection” section. We’ll see a popup with warning message by selecting that option saying that “when library and folder based integration schedules will select, all the Content types will be ignored”, Click on Ok.


We can new section with “Library Based Retention schedule” with description text box. Click on Add a retention stage link to add new retention.




We can see new dialog box specifying the Event and action details. Select the Event and Action for retention stage and click on Ok to save the settings. We can add many retention stages for the document library. Click on Ok in Library Based Retention Schedule page to save the settings.

Wednesday, November 27, 2013

Gantt view errors in SharePoint site- “Microsoft.SharePoint.SPException: This view requires at least Microsoft Internet Explorer 7.0, Mozilla FireFox 3.0, or Apple Safari 3.0.”

In SharePoint 2010, sometime we try to browse the gantt index pages, we can see the error as “Microsoft.SharePoint.SPException: This view requires at least Microsoft Internet Explorer 7.0, Mozilla Firefox 3.0, or Apple Safari 3.0.” as shown the image below.


We can get this error when user agents in SharePoint are not permitted to crawl the content in SharePoint index server. We can fix this by changing Gathering manager value in Registry. To do that Start -> Run -> Regedit


Navigate to following path,
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Office Server\14.0\Search\Global\Gathering Manager


In Gathering Manager, Search for “User Agent” and edit the value. Update the value to
Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.3; .NET4.0C; MS-RTC LM 8; Tablet PC 2.0)


Click on Ok Save the settings and restart the server.

Tuesday, November 26, 2013

Document information panel in SharePoint

Document information panel in SharePoint contains Meta data about document. This will enables users to enter metadata regarding the document. Documents stored in library will contain other columns to show metadata. Document information panel will display the field for each content type property or column that user can edit.
Document management panel allows users to enter metadata for Microsoft based documents that stored in SharePoint. This will not display by default with the document. We have show this by changing the settings for content type.

We can enable document information panel using the steps below,
Navigate to SharePoint Document library Settings page, Click on the content type which to enable Document Information Panel should be enabled.



Click on Document Information Panel Settings in settings section.



In Document Information Panel Templates section, we can specify the default template or custom template. Select “Always Show Document Information Panel on document open and initial save for this content type” Check-box in Show Always section, Click on OK to save the settings.



By editing the document uploaded to document library we can see the fields as shown below.



Wednesday, November 20, 2013

Difference between Cumulative updates, Service Packs and Public Updates

While applying the updates in SharePoint I have a lot of confusion every time in Cumulative Updates, Service Packs and Public updates. By going through articles in TechNet and some of blog posts, i have found the following differentiation among them.

Service Pack:
It’s an update or combination of previous updates helps to make our product more reliable. It includes new fixes, functionality additions and all fixed that released previously (means Previous Service packs, Cumulative updates). That means if MS people released a service pack recently means that contains all the list of features up to date.

Service packs will not be multilingual. We have to download and install separate service packs for each installed language. We must install service packs for specific product as soon as possible. Microsoft provides all the latest fixes and updates in Service pack. There are no prerequisites for Service pack installations because each service pack includes all the recent updates from product release. Service Packs will not release frequently.

Cumulative Update (CU):
Cumulative update is collection of all the hot-fixes up to date. Generally Office hot fixes are released for every two months in a package. It includes fixes for all the issues collected from hot-fix accepted criteria that related to customer impact or reproducible. 

Cumulative update also includes critical on-demand hot fixes and security updates. It includes all the previous cumulative updates and public updates from previous service pack release. Cumulative updates are multilingual. It includes fixes for all languages. To install CU in our machine,, we have to install recent service pack related to that product (If released). 

Generally cumulative updates are not mandatory to install. We can install them to fix any issue. While downloading CU itself we can see the applicable scenarios in KB article page. There is lot of chances to affect the system. So we have to check before installation or advised by Microsoft people support to install. Cumulative updates releases frequently for a second month like (Feb, April, June, Aug, Oct, Dec)

Public Update and Critical On Demand:
Public update includes product fixes that applicable to large number of customers. Public update also applies for multilingual. To install public update we have to install most recent service pack if released. Sometimes Public Updates may have prerequisites for Cumulative updates also.  Public Update includes security fixes and it is recommended to install ASAP.

Critical On Demand will applicable for less number of customers facing critical problem. It will applicable for a specific problem or issue. COD is not multilingual. We have install COD’s on Microsoft people recommendations only.

Monday, November 11, 2013

Work management service application in SharePoint 2013

We have a new service application in SharePoint 2013 to track the user tasks distributed across the sites/site collections/web applications. This will provide to aggregation of the tasks to a central location in SharePoint server. By using this service users can view their to-do tasks in personal site level. All the tasks will be sync into outlook. We can also see the tasks from Exchange, project server. Based on the provider model, users can sync with other systems. We can see all the tasks in my site tasks.

To view the tasks we have to check with following things,
  • We have to check each of the search service should have valid content source and it should be in Continuous crawling. If we have incremental crawls, crawl should happen in very often time intervals.
  • Application pool using for my site should have SPDataAccess SQL permissions in the content database of the web application.

Work Management Service will work on Search. If crawl was not proper, we cannot see any tasks to display. All the tasks used to store in “WmaAggregatorList_User” list in personal site of individual users.  All the tasks can be viewed tasks page of my site.  We can see the tasks in different sections as, important and Upcoming Tasks, Active Tasks, Completed Tasks.

To Create Work Management Service Application, Navigate to Application Management in SharePoint central administration, select Manage Service Application link.In Service applications page, create new Work Management Service Application, and specify the details as shown in the images below. 





This service will have dependency on User Profile Service and Search Service.
We can see the error with yellow warning triangle as “We are having trouble refreshing your tasks” error on “My Tasks” page as shown below.



We can see this error for multiple reasons,
  • Work Management service application was not created.
  • Work management service application dependent services may not running (Search service or search crawls)
  • Account using for Work Management Service Application is same as Web application or Service Account running for Work Management Service Account is not having full Permissions for User Profile service application.

We can see more details on Work Management service application in the following links

http://www.sharepointcolumn.com/work-management-service-application-in-sharepoint-2013/

Thursday, November 7, 2013

Image sliding in SharePoint using Picture Library Slideshow WebPart

We can get image sliding functionality using SharePoint inbuilt WebPart “Picture Library Slideshow WebPart” Using this in-built WebPart we can slide the images from SharePoint picture Library. We can create and display the slideshow in selected page.

We can add image slider to a page by using the following steps,

Edit SharePoint Page, Click on Insert tab from Ribbon, Select WebPart button to insert the webparts. From categories list, Select “Media and Content” group, Select “Picture Library Slideshow Web Part” and click on Add button to insert the web part.



Edit the web part to specify the images source to display images.



We have to specify the slide duration, Picture Library, Order in webparts edit pane. Click on OK.



We can see sliding images once we updated with the webparts properties.  This helps us to image sliding instead of creating custom images.

Thursday, October 31, 2013

Disabling mobile page redirection in SharePoint 2013

SharePoint 2013 is supported for mobile devices and it will detect the request from mobile devices according to the request it will changes the URL of the page automatically. Mobile view is different from the desktop view in SharePoint. SharePoint is having complete different controls for mobile pages.

We are having Microsoft.SharePoint.MobileControl namespaces for mobile pages which inherits from System.Web.UI.MobileControls namespace. Whenever mobile device request is detected, it will redirected to mobile devices optimized version pages. By default these pages will be located in “_layouts/mobile” folder. By default the team site redirects mobile home page “_layouts/mobile/mblwp.aspx”. We can customize the home page for the mobile devices.

We can restrict redirection for mobile pages, by adding the below lines in web.config file System.web for SharePoint web application

<browserCaps>
<result type="System.Web.Mobile.MobileCapabilities, System.Web.Mobile,            Version=2.0.0.0, Culture=neutral, PublicKeyToken=d04e4d2a43f43d3e"/>
<filter>isMobileDevice=false</filter>
</browserCaps>

Wednesday, October 30, 2013

SharePoint custom workflow Error – This view cannot be displayed because the number of lookup and workflow status columns exceeds the threshold”

While working with SharePoint custom coding on lists, I got an error saying that “This view cannot be displayed because the number of lookup and workflow status columns it contains exceeds the threshold..”

After googling in to the issue, I have found the solution in this post. We can see this problem due to lookup columns value exceeds the SharePoint environment configuration value. When tis error occurs, SharePoint web services will refuse to return the documents. By increasing “List View Lookup Threshold” value, we can fix this error.
We can increase the limit in SharePoint central Administration by using following steps,

Navigate to application Management in SharePoint Central Administration and click on “Manage Web Applications” link.



Select the web application to increase threshold value, Click on “Resource Throttling” in General Application Settings in the ribbon.


In List View Lookup Threshold” section we can specify the maximum number of lookup that Specify the maximum number of Lookup, Person/Group, or workflow status fields that a database query can involve at one time. Change the value to bigger and click on OK to save the settings.