How can we help you today?

How to Open Microsoft Office Files Directly in Your Office Client Application (Word, Excel or Powerpoint) from ShortPoint

You have a File list (or any other) ShortPoint connected to files in your document library and you want to launch Microsoft Office client application directly when clicking on the files (type: Word, Excel or PowerPoint):

To use the above ShortPoint with the given design and code, please copy the ShortPoint code below to your page:

[files-list color="highlight"][file-list-item shortpoint_connection="'Templates')%2Fitems%3F$select%3DFileLeafRef%2CEncodedAbsUrl%2CModified%2CCreated%2CEditor%2FTitle%2CFile_x0020_Type%26$expand%3DEditor%26$" title="%23FileLeafRef" subtitle="created%20by%20%23Editor__Title" file-type="%23File_x0020_Type" link="%23DirectUrl" /][/files-list]


  1. You need to be logged in at Microsoft Office with the same account as you are logged in to your browser

  2. You need to have Microsoft Office Installed at users' machine

Step 1: Add File Lists ShortPoint to the page

Add any element to the page In this example, I am going to add File Lists ShortPoint but this solution is not restricted to it.

Go to Connect and Select Rest API connection type;

Step 2: Connect to files and make it open with Microsoft Office client application

https://<Tenancy Name>'<Document Library Name>')/items?$select=FileLeafRef,EncodedAbsUrl,Modified,Created,Editor/Title,File_x0020_Type&$expand=Editor&$orderby=FileLeafRef%20asc

<Tenancy Name>: This should be URL to your web (for example

<Document Library Name>This should be the title (Name) of your document library

To have more options about sorting the file list, you can follow How to show both Files and Folders of the Document Library in your ShortPoint element article's Step 2.

Example URL:'Templates')/items?$select=FileLeafRef,EncodedAbsUrl,Modified,Created,Editor/Title,File_x0020_Type&$expand=Editor&$orderby=FileLeafRef%20asc

Now we need to make a URL which will make files open directly in Microsoft Office Client application. To do that, check Enable Advanced Settings and provide following JavaScript code in Map Results:

var files = data.d.results;
var filesWithDirectUrl = {
if(file.File_x0020_Type == "docx")
file.DirectUrl = "ms-word:nft|u|" + file.EncodedAbsUrl;
else if(file.File_x0020_Type == "xlsx")
file.DirectUrl = "ms-excel:nft|u|" + file.EncodedAbsUrl;
else if(file.File_x0020_Type == "pptx")
file.DirectUrl = "ms-powerpoint:nft|u|" + file.EncodedAbsUrl;
file.DirectUrl = file.EncodedAbsUrl;
return file;
return filesWithDirectUrl;

Click Connect. 

Here are the sample mappings in Item tab, however you can do mappings the way you want:

That's it!

Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.

World's best intranet sites are designed using ShortPoint

Get started today! Learn more
See all 31 topics

Start a trial

Ignite your vision. Install ShortPoint directly on your site, or play in sandbox mode. No credit card required.

Get started today

World’s best intranet sites are designed using ShortPoint

Thousands of companies using ShortPoint everyday to design, brand and build award winning intranet sites.

Get started Learn more