PowerPoint Hub

 

How to Set Up PowerPoint Add-In

  1. Open the file web.config from the SmartHub root folder.

  2. Remove the X-Frame-Options and Content-Security-Policy headers.


  3. Navigate to the SmartHub directory: <SmartHub_Installation_Root>\integrations\powerpoint\

  4. Edit the configuration file BAInsight.OfficeAddIn.PowerPointManifest.xml.

  5. Replace all occurrences of the URL https://smarthub.contoso.com with the SmartHub address.

  6. Go to line 125 and modify the parameter SmartHubAddressEncoded with your index page of your SmartHub.

Example

Copy
<bt:Url id="Upland.Taskpane.Url" DefaultValue="https://smarthub.contoso.com/integrations/powerpoint/Login.html?redirectUri=https%3A%2F%2Fsmarthub.contoso.com%2Findex.html%23pn%3Dpowerpoint" />

Decoded default value for line 125

https://smarthub.contoso.com/integrations/powerpoint/Login.html?redirectUri=https://smarthub.contoso.com/Index.html#pn=powerpoint

URLs can be encoded by opening a Browser Console (F12) and applying encodeURIComponent function to desired URL:

  1. Navigate to the SmartHub directory <SmartHub_Installation_Root>\integrations\powerpoint\powerpointCustomSettings.js

  2. Search for SH.AuthDialog.CustomSettings and replace the occurrence of the URL https://smarthub.contoso.com with the SmartHub address.

  3. (Optional) You can change the icon of the app by changing the IconUrl setting in the manifest file.

How to Install PowerPoint Add-In (Organization)

An admin can assign the PowerPoint add-in directly to a user, to multiple users via a group, or to everyone in the tenant.

The following steps describe how to install the PowerPoint Hub at an organizational level:

  1. Access the Services & add-ins page as an Administrator: https://admin.microsoft.com/AdminPortal/Home#/Settings/AddIns



  2. Click the Deploy Add-in button.

  3. Click Next.

  4. Click Upload custom apps.


  5. Select "I have the manifest file (.xml) on this device."

    1. Click Choose File and browse to the .manifest file delivered with the SmartHub package.


  6. Click Next.

  7. Asign Users (Everyone).


  8. Click the Deploy button.

  9. From this point, the Hub is available to all of your users.

How Users Enable SmartHub in PowerPoint

  1. Users can enable SmartHub in their PowerPoint instance by going to Home > Add-ins > More Add ins > Admin managed and add "SmartHub ".


  2. The SmartHub button can be found in PowerPoint > Home > Show SmartHub.



How to Install PowerPoint Add-In (Independent)

  1. Go to PowerPoint 365 (it works only for PowerPoint browser version).

  2. Open a presentation.

  3. From the menu bar, Select Insert > ... > Add-In > M ADD-INS > Upload My Add-in > Browse. Select the Manifest file and click Upload.

  4. After these steps, you should be able to access the SmartHub from your presentation.


Note: To remove the add-in if installed via user-managed add-in section, one must navigate to the Local Storage and delete the manifest from there.
This is a PowerPoint Add-in issue.
Open the Developer console.
  1. Select Application Tab -> Expand LocalStorage

  2. Select https://powerpoint.officeapps.live.com -> Filter for “SmartHub”

  3. Select the PRIVATEMANIFEST

  4. Verify that the smarthub site link contained in the Key Value is the one used for the PowerPoint Add-in

  5. Delete the Key (after confirmation)

Exposed Functions and Available Events

Info: There are 3 functions and 2 events exposed by SmartHub PowerPoint Add-In.
These functions can be used to insert slides from search results into current presentation.
The events can be used for example to return different messages in UI, or to display a loading icons/message for end users.

Available Events

Event name Trigger
GetSlideBase64 Triggered when getSlideBase64 is called.
ReceivedSlideBase64 Triggered when Base64 data was received.
AddingSlide Triggered when the slide is starting to be added in current presentation.
DoneAddingSlide Triggered when the slide was added.

 

Exposed Functions

Function Name Function Call Description
window.SH.PowerPointGetSlideBase64 window.SH.PowerPointGetSlideBase64(url)
  • This function can be called in order to get the base 64 of slide.

  • "Url" pameter represents the URl configured with DocLoader.

window.SH.PowerPointGetSlideBase64(url) window.SH.PowerPointInsertAfterSelectedSlide(base64Blob, formatting)
  • This function can be called in order to get the base 64 of slide.

  • "base64Blob" parameter represents the base64Blob returned from above function.

  • "formatting" parameter represents the slide format that you want to use for the inserted slide

window.SH.PowerPointInsertPowerPointSlide window.SH.PowerPointInsertPowerPointSlide(url, formatting)
  • This function can be called in order to insert the slide in your powerpoint presentation. It is a shortcut for above functions(PowerPointGetSlideBase64 and PowerPointInsertAfterSelectedSlide).

  • "Url" pameter represents the URl configured with DocLoader.

  • "formatting" parameter represents the slide format that you want to use for the inserted slide