Monday, October 24, 2016

PowerApps at Collab365 Global Conference 2016

I got the opportunity to speak at the Collab365 Global Conference 2016 on Exploring the PowerApps advantage. Got a really good audience along with good feedback on the content as I made the PowerApps created accessible online during the time of the presentation.

The session held on 19th October 2016.

Custom APIs with PowerApps and Microsoft Flow at Monthly Meeting

SharePoint Sri Lanka Monthly Meeting for October 2016 was held at Microsoft Sri Lanka on 12th October 2016.

Thursday, September 15, 2016

Exploring the PowerApps Advantage at SharePoint Sri Lanka Monthly Meeting

SharePoint Sri Lanka Monthly Meeting for September 2016 was held at Microsoft Sri Lanka on 14th September 2016. 

The session was at Level 100 and targeted for the basics on how to build and use PowerApps. The introduction was followed by a couple of demonstrations where the attendees were provided with hands on experience to browse the apps built during the demonstrations.

PowerApps looks promising and it may help many organisations largely in future by providing an easy platform for building apps without much code. 

The ability to connect to multiple services as well as make your own storage through the Microsoft Common Data Model will keep attracting many solutions to be built with PowerApps.

Wednesday, August 17, 2016

Getting Started with PowerApps

The ever increasing demand for the business solutions are not met with the poor supply from the development sometimes. Therefore many companies tend to go with the no-code or less-code solutions and SharePoint has been a leader with many Out-of-the-box components. With the solid APIs build in around the services, Microsoft has enabled much better no-code implementations. Initially it came in with Windows App Studio where it allows you to create Windows Apps without any coding. Now its up for many services within the cloud and relevant API integrations with the name of PowerApps. 

PowerApps allows you to create business apps without any code. The controls are just drag and drops and there are many types of services to choose from.

  • SharePoint Online
  • SalesForce
  • Google Drive
  • Dropbox
  • Slack
  • Office 365
  • Azure and many more...
You just need to have an organizational Microsoft account in order to Sign Up and can start by downloading the Windows Store App on your Windows machine.

Monday, July 11, 2016

Associating SharePoint 2013 Workflow to a list

SharePoint 2013 supports Workflow Manager workflows. Which means they totally different with 2010 workflows. In reality what happens is that we publish a subscription for the particular list. Though its been a while SharePoint 2013 has come, I have seen many people struggling without getting this done. So I thought its worth sharing a sample code snippet with an explanation.

To get a detailed explanation, we need to have a little understanding on the following classes. 

Thursday, July 7, 2016

Copying a SharePoint list from one site to another

Copying a SharePoint list from one site to another as there are many approaches. There are many options available such as,

  • Saving as a list template
  • Using PowerShell
  • Inline Copy and paste and etc...

Depending on the level of information you have, you might need to consider using a third-party tool as well when you have a complex structure that may include different site columns and so on. Migrating SharePoint data from one to another is a different BUSINESS.

Wednesday, June 15, 2016

SharePoint WebHooks Advantage

It is just announced that SharePoint will start supporting WebHooks and I got to know the news through the PnP WebCast. I through of just summing up a few advantages for the implementations that align with the WebHooks over the other mechanisms available. At first glimpse it looked like a replacement to the remote event receivers, but both have their own advantages. As the full details of the implementation is yet to come, my assumptions are based on what is announced so far.

First of all, WebHooks is a callback mechanism that supports notifying the changes rather than waiting clients to query it every time. Once subscribe with an expiration time defined or not, it will keep sending the update notifications until it is acknowledged through the endpoint. It is said SharePoint will support subscriptions with expiration date up to 6 months since its initial subscription. 

Tuesday, May 31, 2016

Consuming SharePoint Data on Cross Platform Apps

So Xamarin is freely available with Visual Studio 2015 Update 2. I wanted to tryout building a cross-platform application that consumes SharePoint Online data. Earlier I provided the CSOM code sample which allows you to interact with SharePoint On-Premise and Online within a universal application. But this time I am going to try out and Android. 

As the tryout is still in progress, I will update sooner the implementation is done. 

Before that, you need to have Visual Studio 2015 with Update 2 that has inbuilt support for Cross-Platform development upon selection during the installation. (This is the easiest way, of course you can install Xamarin separate and use Xamarin studio as well.)

The setup will take around 33GB across all the drivers during the installation.

Stay tuned... This is going to be awesome.

Thursday, May 5, 2016

SharePoint Framework for developers

Let me start with simply stating this is the best news I heard about SharePoint as a developer. As it is announced at the Future of SharePoint, SharePoint Framework is a Page and Part model that enables fully supported client-side development. This means the client-side development models on SharePoint just got even better. 

Microsoft has been very busy providing new APIs frequently for supporting multiple technology stacks throughout the past few years and they kept trying making these APIs platform independent with the JavaScript and REST API support. This is made even simpler and understandable with the support of the Microsoft Graph API though it is still at a level of gaining the best maturity when accessing Office 365 components. 

Friday, April 29, 2016

Speaking at Collab365 Summit 2016

In case if you do not know yet, Collab365 is huge this time. Its going to be Online from 10th to 12th May 2016 live from Microsoft HQ. If you are not registered yet, go and Register through the following link.

With 12 more days to go I thought of writing up something about the session I am yet do deliver. I will be speaking on "Workflow Manager Troubleshooting and Experience". This will include some of the experience we had by building a considerably large workflow management system and automating several business processes.

Friday, April 22, 2016

Getting over with the Lookup field unavailability issue

I have been facing this issue quite sometime when creating a lookup field of a SharePoint list. The main suspect was the title field. 

As we create a lookup to a list we tend to use the title field as the lookup field. Also we are tend to rename it in order to easily get the field with link and actions. 

For example, lets assume we rename the title field as "Name" with the "MasterList". Still its internal name will be Title.

Now in the child list, we need to lookup the "Master List". What we need to do is simply lookup that name field. We can simply do it through the C# code. But SharePoint creates this within the internal name. So it expects the Title field to be there. 

The best way to avoid is setting up internal name when creating the lookup. This prevents any issues with the lookup. 

If you are ever mistaken with that and have used the display name, you can simply go to the column settings and save it even without any changes. This is a tricky way to get over there.

Regardless of trick, its always good to use the internal name.

Monday, April 18, 2016

SharePoint CSOMs for Customizations

One of the biggest questions that you may encounter if you are using the Managed Client Side Object Model for SharePoint development these days is picking up the correct version of the dll. Here is one of the screenshots captured through my dev environment.

As you can see in the above image, there are two versions of dlls available for each dll under different version numbers. 

Monday, April 4, 2016

C# Associating a Workflow Manager Workflow to a SharePoint list

Workflow Manager workflows are different to the prior versions as it follows a subscription based model for creating associations for the Workflow Manager. In this article I am planning to showcase the code snippet which allows associating a workflow to a SharePoint list as it is not much famous and mentioned at many places.

Friday, March 25, 2016

SharePoint PowerShell CSOM send email

In my previous article I explained about reading a SharePoint list using SharePoint PowerShell CSOM. In this article I will simply explain how to send an email using SharePoint PowerShell CSOM. 

In order to do this, you need to have the PowerShell CSOM setup done as I have explained in my previous article

An email can be simply sent using the SendMail method of the Utility class through the following code.

$email = [String[]]($email_receiver)
$emailProperties = New-Object Microsoft.SharePoint.Client.Utilities.EmailProperties
$emailProperties.To = $email
$emailProperties.Subject = $email_subject
$emailProperties.Body = $Body

Thursday, March 24, 2016

Client-side SharePoint PowerShell CSOM Read list

SharePoint PowerShell API provides the capability to connect to SharePoint 2010, 2013 and Online. The major advantage is that these can be run from a remote machine. The API is available in CodePlex.

I will focus on how to use the API and read a SharePoint list in this article.

First we need to download the source from CodePlex and extract it to a directory with necessary permissions. I am using 'C:\SPPS\Source' as the location for extraction.

Next we need to get a client context as in a normal CSOM.

Wednesday, March 16, 2016

C# CSOM SharePoint Online Authentication

SharePoint Online authentication via C#.NET Client-side Object Model is simplified with the SharePointOnlineCredentials class. Usage of this has been explained in Vardhaman Deshpande's blog. Usage of this within a Windows Phone app and exception handling is explained in this article.

I have attempted this within a console application as well as in a Windows Phone 8.1 App built using Visual Studio 2013 with Update 5. Basically it will work within Universal Apps.

  • When using the Console Application you need to reference the Microsoft.SharePoint.Client assembly.
  • In order to use this within the Windows Phone Application you need to reference the Microsoft.SharePoint.Client.Runtime assembly. 

The code sample is as follows, in order to proceed with operations, you need to follow the context load and execute query model.

Monday, March 14, 2016

C# CSOM SharePoint authenticating Online and On-Premises

Recently I had the need to implement an authentication scenario for both SharePoint Online and SharePoint 2013. The authentication credentials for both scenarios are handled through different classes within different namespaces. First, let me share the two code samples for both.

Monday, February 29, 2016

Updating Distributed Logon Cache Settings on SharePoint Farm

As you may know, the distributed cache service on SharePoint 2013 helps improve the performance of many components such as,

  • Authentication
  • Newsfeeds
  • Security Trimming
  • Page load performances and etc...

There are different caches exist under the distributed cache service.

The Login Token Cache, which is named as DistributedLogonTokenCache stores security token issued by a Secure Token Service for use by any web server in the server farm. When any web server receives a request for a resource, can access the security token from the cache in order to authenticate and provide access to the resources.

Tuesday, February 16, 2016

Handling ETag value on SharePoint REST API Updates

ETag value is a part of the HTTP protocol that allows concurrency control and web cache validation. ETag is a broader topic when considered in general, but the main focus on this article is to discuss about REST API usage within SharePoint. 

ETag value is used whenever we make a POST request to a REST API endpoint. This is handled through the IF-Match request header. A sample request is displayed below.

Monday, February 8, 2016

Integrating SharePoint to a Universal App

Recently I came through a requirement that I thought worth trying out a Universal App that consumes SharePoint data. I have chosen Windows 8.1 and Windows Phone 8.1 as the minimal platforms and to support upwards. 

Universal apps bring the power of writing one code that work on both phone and desktop/ tablet devices. This can be done easily in order to create an app that consumes SharePoint data.

This is made simple with the support of C# Managed Code Client Side Object Model. What you need to do is to reference the client side assemblies along with the run-time assemblies. 

Friday, February 5, 2016

SharePoint Workflow REST Call Failure

SharePoint Workflow Manager workflows allows creating workflows that communicate with the SharePoint objects through the REST API calls. End of the day a REST API is connected through the Client.svc endpoint of a particular site. Somehow there are situations I have experienced Cancellation of workflows due to the failures of REST calls. 

There are instances where when you make too many REST API calls, a 429 HTTP Status Code is returned. I have explained this in one of my previous articles here. That is a carefully handled scenario of the Client.svc.

Thursday, January 28, 2016

SharePoint DateTime field REST API Time Zone Issue

We all think this is an issue, but it is not. REST API for SharePoint has its own way of handling things compared to the other APIs. There are a few things we need make note.

1. SharePoint stores date in 0000 UTC timezone. 
2. We have a different regional setting (timezone) for the SharePoint site.

Friday, January 15, 2016

WFInstanceManagementDB in Workflow Manager

WFInstanceManagementDB database plays a vital role in the SharePoint Workflow Manager workflows. This will maintain the list of instances that are being used by the Workflow Manager and associated related data. 

I could not find any recommended guidance for browsing and modifying these data in these workflows. So it is better do any operations associated with these databases with a possible risk in mind. I would not go and modify any of these databases.

But it will give an idea on how it is handled. Also it is not too complex.

Sunday, January 10, 2016

Setup SharePoint Environments on Azure for Development - Part 1

There are lot of developer platforms being moved to the Azure and other cloud platforms considering the many capabilities and benefits it has. In this article, I will be writing about how to setup a SharePoint development environment to a whole development team. This is with experience and I will be focusing considering a combination of following SharePoint Server roles as a developer environment. 

  1. A shared domain controller
  2. A shared database server
  3. A shared workflow manager farm
  4. Non-Shared SharePoint Application Server

Tuesday, January 5, 2016

Starting SharePoint Workflows with PowerShell

PowerShell is often used for many activities related to SharePoint. For any quick fixes around can be handled easily with PowerShell. Its no doubt Workflows are a vital part of SharePoint and with SharePoint 2013, they are not anymore in the SharePoint. 

Another important thing is that we often run SharePoint 2013 Management Shell as the administrator. But it is recommended not to use a SharePoint service account for running workflows. Well, it does not work. 

This makes starting a workflow tricky. We can get over with this through two tricky ways. One is granting another user with a Shell Admin permissions. But I would not recommend that. So the answer is simply impersonating a user.