Wednesday, 8 June 2016

Automatic refresh issue with embedding PowerBI reports in SharePoint Online

I could talk about benefits of embedding Power BI reports in SharePoint for days but as there is no shortage of good blogs out there covering that topic already so instead my focus here will be to talk about overcoming a challenge of using SharePoint lists as a data source given Power BI’s data refresh limitations.

I recently worked on a project which required me to use a SharePoint list as a data source, and to connect that list to PowerBI. Users could then analyse and create reports using the SharePoint data, before embedding those reports in a SharePoint site so as to visualise the live data for internal and external users. 

To clarify this process I’ve drawn up a simple diagram:

Connecting a SharePoint list to PowerBI is very straight forward and took me no time at all. Analysis and reporting can also be done fairly easily in PowerBI and I left this to the users to work on.

Next, I created a SharePoint Online App/Add-in Part to display Power BI Dashboard Tile. 

Here are the high level steps to you need to take to create the App/Add-in:

      1. First you need to register your Power BI web app in Azure Active Directory. This establishes an identity for your application and enables you to specify permissions to Power BI REST resources.
When you register a web app, you receive a Client ID and Client Secret. The Client ID is used by the application to identify itself to the users tharequesting permissions from. The client secret Key is used by the web app to securely identify itself to the Power BI service.

     You can register your web app either with the Power BI App Registration Tool or on the Azure with the Power BI App Registration Tool or on Azure Management Portal. The Power BI App Registration Tool is the easiest option, since there are just a few fields to fill in. Click here for links and more information
       2.  Next Create a Provider Hosted Add-in using Visual Studio. Make sure to use a developer site on O365. Select SharePoint Online for target SharePoint version, 'MVC Web application'  for project type and use Windows Azure access control service for authentication setting.
           3.  Create a solution using codes from here or here
       4.  Once the SharePoint Add-in is created, it can be added on to any SharePoint page

Having carried out these steps, we were understandably excited about having our pretty visualisations added to the SharePoint site. But then…

DISASTER! We realised that by editing our SharePoint list items, our visualisations weren't being updated, as the connection is not real-time and the automatic refresh doesn’t apply to SharePoint list as data source. 

After a short period of mourning, and some hasty research, I learned from this link that the Live/DirectQuery feature for SharePoint is not available at the moment. Was this the worst day of my life? Perhaps not. But it was certainly the worst day of my life to involve an issue with PowerBI.

After more research I soon found a way to overcome this issue by using Azure SQL database, here is how I did it:
  1. Create a database table that stores list items/content in an Azure SQL Database.
  2. Create a CRUD connection between Azure SQL Table and SharePoint Online using ‘Business Connectivity Services’ in conjunction with ‘Secure Store Service’.  Check the step-by-step details here & here.
  3. This would enable creating an External List in SharePoint and users can benefit from using a single platform for creating/editing items on the list and we avoid any custom service in between these services.
  4. Finally, Power BI can directly connect to Azure SQL Database with the auto refresh option and provide a real-time report of the data.
           To illustrate this entire process I’ve drawn up another diagram. 

Tuesday, 11 November 2014

 Versioning is enabled by default in SharePoint Online.

What is versioning?

When versioning is enabled in site lists, you can track and manage information as it evolves. You can look at earlier versions and recover them, if necessary. That is very handy, for example, when people realize that earlier versions of an item might be more accurate than later ones. Some organizations retain multiple versions of items in their lists for legal reasons or audit purposes.

Microsoft received large number of queries in past when users had made changes to a particular file and they wanted to restore it as they did not had versioning enabled on the library as it was disabled by default, the only option was to restore the site collection to specific point of time which means all the data that was modified meanwhile will also get restored as well also the restore process takes around 72 hours.

Having versioning enabled on the document library was the only option through which item level restore was possible.

Therefore, For all the new libraries that are created on SharePoint Online, versioning would be enabled by default.

Tuesday, 11 June 2013

Switch SharePoint Online Newsfeed to Yammer

What is Yammer?

Yammer is as easy to use as great consumer software like Facebook and Twitter, but is designed for company collaboration, file sharing, knowledge exchange and team efficiency.

How to switch from SharePoint Online Newsfeed to Yammer?

By default, the SharePoint Newsfeed is your Internal Social Network.

Now this can be changed to Yammer and here is how: First Sign in to Office365 portal using a global admin account and navigate to SharePoint.


From SharePoint Admin center click on Settings and change the Enterprise Social Collaboration from default to Use service. Once the change is saved you should be able to see that the SharePoint Newsfeed link is replaced with a link to Yammer. This update could take up to half an hour in my case it took about 6 minutes.


How do users sign in to Yammer? is a separate service from Office 365 and requires separate account credentials. Microsoft is working on single sign-on authentication, but it’s not ready yet, so how do users sign in? If your users already have account they can sign in with their Yammer accounts and if not, they can sign up for free (if you’re a Microsoft Enterprise Agreement customer).

What happens to the Newsfeed?

When your organization switches to Yammer, SharePoint Newsfeed functionality doesn't go away. People can still access Newsfeed from their Sites page, and they can continue to follow SharePoint sites, documents and tags there. However, they no longer have the option to send a message to everyone.

Happy Yammering!

Monday, 25 February 2013

Enabling iOS Mobile Device Management with Windows Intune fails

I just spent two hours trying to set up Windows Intune Direct Management for iOS Mobile Devices and it kept failing when trying to download theIntune app on the device.

The problem occurs when you try to download the APN certificate from Apple Push Certificates Portal using any version of IE. Internet Explorer simply fails to download the certificate correctly although it shows the following message
So to solve this issue close IE, open Google Chrome and login to Windows Intune portal and follow the same steps, I recommend revoking all previous certificates before creating a new one.

Also make sure that the user who will be logging in to Windows Intune portal on their mobile device has a valid licence assigned.

Tuesday, 5 February 2013

How do I automatically redirect all mail from one domain to another in Office365?

There are few ways to redirect emails from one domain to another within an Office 365 account. The easiest one is to set up an inbox rule. 1. Login to Office 365 portal as admin 2. Go to Exchange control panel
3. Click on Mail control and Create a new rule 4.On the Inbox Rules tab, click New 5.Under When the message arrives, select

Thursday, 14 July 2011

Unable to sign out from Office 365 Portal

Office 365's portal is a user friendly web portal that helps you administer Microsoft Online Services for your company.
Few Custmers using internet explorer 8/9 encountered a problem when signing out of the portal. This problem is not a major issue and it's quite easy to fix.
So what causes the problem?
The problem is the add-ons on your web browser which doesn’t let the page to function properly so the page tries to refresh itself failes to sign out and goes back to the portal homepage. This problem is least likely to happen using Firefox.
How to solve the problem?
Open your web browser go to Tools and hit Internet Options, go to Security tab and make these changes in both Internet and Local Internet:
First make sure the Enable Protected Mode box is checked and then click on Custom Level
Do the followings:
1.Permission for component and manifest : Disable
2.ActiveX controls and plug-ins: Allow Previously used ActiveX controls to run without prompt: disable
Now click on Programs tab and then hit add-ons and disable the following if applicable:
Groove GFS Browser Helper
Once you click disable it will disable the Office Document cache Handler and Groove Folder Synchronization automatically.
Note: it requires restarting the web browser to take affect.
Problem Solved!!

Friday, 3 June 2011

Implementing SEO

Search Engine Optimisation (SEO) is the practice of creating or modifying a web site so that it can be properly read and indexed by search engines.
Searchers type in specific words into the search engines and they expect the engines to provide results that match their original query.
The higher a site appears in the search results list (the closer to the top of the first page), the more visitors it will receive from the search engine. SEO may target different kinds of search, including image search, local search, and industry-specific vertical search engines. This gives a website visibility, presence, and helps boost traffic.
This goes back to making sure that you have a strong, search engine friendly website architecture
As an Internet marketing strategy, SEO considers how search engines work, what algorithms they employ, as well as what people search for, and how they search.
There are two types of results found on search engine result pages - links that are there thanks to organic SEO and links that are there due to paid search
Organic search
Organic describes a search that returns results by indexing pages based on content and keyword relevancy.
Organic search engine optimization is the process of improving the volume or quality of traffic to a web site from search engines by means of natural SEO efforts, specifically including the optimization of on-page content.
Google has led the way in championing the virtues of natural or organic search. Its primary focus has always been to return fast, highly relevant results based on the content of the page, the relevancy of links pointing to that page, and other "objective" criteria.

Paid search
Programs such as Google AdWords allow advertisers to bid on keywords they want to match up with their advertisement. When a browser enters one of those keywords in a search query, the advertiser's link and brief description may appear on the following SERP. If a browser clicks on the link, the advertiser must pay a certain amount of money associated with the Pay per clip campaign.
In reality, organic search results are more effective than paid search results because:
There is no cost involved and the returned results are more relevant to the keyword because they are based on quality content and keyword match, usually people who click on organic search results have a higher level of education because they make specific research on academic topics.
Search engine users click on organic search results and especially the 10 first organic results that appear in search engines. This generates more traffic for the website.
The success of an online business greatly depends on the amount of traffic it can generate for its pages. This is an indubitable fact.
Search engine users feel that organic search results are more relevant than pay-per-click ads and they are more trustable to them.

Common search engine principles
To understand SEO you need to be aware of the architecture of search engines. They all contain the following main components:

Spider - a browser-like program that downloads web pages.

Crawler – a program that automatically follows all of the links on each web page.

Indexer - a program that analyses web pages downloaded by the spider and the crawler.

Database – Storage for downloaded and processed pages.

Results engine – extracts search results from the database.

Web server – a server that is responsible for interaction between the user and other search engine components.

Search engines use automated software programs that crawl the web. These programs called "crawlers" or "spiders" go from link to link and store the text and the keywords from the pages in a database. "Googlebot" is the name of Google’s spider software.

Identify the market…
Keyword research is the first step you need to do when planning a search engine optimization strategy.
Create large lists of keywords which can be narrowed down to specific keywords to target immediately, secondary keywords for later on and maybe a third list of “maybes” which you can save for later on.
Organic SEO focuses on the content of your web site– the site must contain the relevant keywords. These must recur in the content an appropriate number of times to maintain a certain density in order to catch the attention of a search engine.
Keyword Density Analysis refers to an automated way to count the frequency of words and/or phrases on your web page.
Keyword density is important because search engines use this information to categorize a site's theme, and to determine which terms the site is relevant to. The perfect keyword density will help achieve higher search engine positions. Keyword density needs to be balanced correctly (too low and you will not get the optimum benefit, too high and your page might get flagged for “keyword spamming”).
Other relevant and keyword rich content should be added on a regular basis to ensure that keyword density does not fall and rankings are maintained or improved.

Optimizing your webpage
Page Content
The second step is to use the keywords in an appropriate way in the website.
The search engine spiders will read this content in determining how to rank the website.
Place your targeted keyword phrase in your content as often as possible while keeping the content easily readable by a live visitor. The goal here is not to sell to search engines; it is to sell to people, it’s also important to convey the right message to the right audience.
Sprinkle the keyword phrases evenly throughout the content; this is the phrase that the searcher was searching for. When they see it on the page it will be a reminder to them what they are looking for and seeing it a few times will reinforce that you can help them find the information they need to make the right decision.
Providing new content regularly will help bring people back and also Google and other search engines love fresh and unique content.
Optimizing for synonyms of the target keywords, in addition to the main keywords is very useful as for which search engines are smart enough to use synonyms as well, when ranking sites.
Meta Tags
Your description should highlight your keyword phrase, keeping it focused, to the point and readable. Your keyword tags should also be focused using each keyword a maximum of 3 times in any set. These tags should be customized on each page to fit the specific phrase targeted.
Meta tags go in between the "opening" and "closing" HEAD tags. After the Meta tags have been inserted appropriately to fit each page it is important to title each page appropriately. The main targeted phrase should be the focus of the title, keep it simple, focused, to the point, do not bog it down with extra descriptive text, this is not your description, it is your title.
Page Title Tag
Google uses the title tag in its link to your site in the search engine results. By putting your keywords in the title tag, you will gain a higher ranking in Google and other search engines. Title is weighted quite heavily, since it's a short description of the content on the page. You should use your targeted keywords for a specific page in your title tag.
The HTML title tag isn't really a Meta tag, but it's worth discussing in relation to them. Whatever text you place in the title tag (between the and portions as shown in above will appear in the reverse bar of someone's browser when they view the web page.
When a keyword in the document text is in a larger font size in comparison to other on-page text, this makes it more noticeable, so therefore it is more important than the rest of the text.
The "Alt text" refers to the "alt" or "alternative" attribute used in the image tag, it's purpose is to provide some alternate text to describe the image in the event that a browser has image loading disabled, or the person viewing the web page is unable to see the image.
Spiders don't read images but they do read their textual descriptions in the tag, so if you have images on your page, fill in the tag with some keywords about them.
Page URL
If you want your web pages to rank high in search engine result pages, then you should make sure your URL is properly optimized. This is one of the important on-page optimization technique.
Searchers tend to click more on readable URLs as they give us idea about the actual content on the web page. For this reason you should avoid using dynamic URL and stick with static URL.
An example of a good URL:
A dynamic URL is having characters such as “=”, “&” and “?” in the URL. In general, dynamic URL content gets indexed very slowly and some search engines might have problem indexing it, also you should keep only keywords in URL and remove all numbers and words such as “the”, “of”, “in”, “your” and etc.
Always put the primary keywords near to the starting point of your URL, because search engines think that words at the left hand side of the URL are the most important keywords and also separating multiple keywords in URL using hyphens will make it easier for search engines to understand your URL structure and exactly when it starts and when it ends for each keyword.
Link Popularity
A large part of SEO is the effort spent obtaining links from other relevant web sites. This can be very time consuming, and frustrating as well. However, it's the number of incoming links that Google uses to assign PageRank. The higher your PageRank, the easier it is to get to the first result page of Google for your phrase.
The most effective way to increase your search engine rankings is to embed internal links in your page content pointing to another page of your site. Google gives better ranking to websites with more total number of internal links this tool is called Link Wheel.
External links are link pointing from your website to other websites. It’s a good practice to refer your visitors to resources outside your website.
Having links from similar sites is very, very useful. It indicates that the competition is voting for you and you are popular within your topical community.
Incoming links from high authority site certainly help to boost your rankings in search engines especially those websites with high PageRank. Authority sites are those websites that have been established for quite a while and usually have high search engine rankings.
Link Wheels
The basic concept of a link wheel is nothing more than creating multiple Web 2.0 properties on the Internet that inner link to each other and also link out to your main website and in effect make a wheel of sites that link together.
The more external web 2.0 sites you include in your link wheel will help re-enforce the link strength to your main site, but also can drive some healthy direct traffic to your sites as well. Plus you are building an authority presence on the search engines, so you will benefit in raised Google rankings for your keyword phrase so when you could have as many sites as you like sites in your link wheel.
Avoid broken Links
Link validity is included as one of the important factor in user experience design.Broken links, both internal and external, are bad for visitors because they give the impression that your site is not well maintained. Not only that, they’re also bad for SEO because search engine bots will stop from crawling all your pages if they meet a broken link.
Google specifically advises webmasters to check for broken links in its web design guidelines.Placing the NoFollow link attribute on your website is a very important SEO factor for on-page optimization. Getting backlink juice to websites isn't that easy for everyone, so we need to make sure the juice flow is flowing properly.