Dec 15

Box Viewer Prefab

The Box preview prefab enables preview of hundreds of different file formats including all Microsoft Office Documents images, videos, 3D models etc. It uses the Box preview API provided by a developer account of Box Platform.

Prerequisites of using the prefab are :

  1. A Developer account in box.com
  2. Create an app(https://app.box.com/developers/console)
  3. Generate a Public/Private key pair for the app
  4. Download the App Settings as json.

 

Now drag and drop the prefab into the page of your project. And set the App Environment. In your app’s Settings > Config profile > Box prefab > App Environment, add key-value pairs for the respective field from the downloaded App Settings json.

Now bind the URL property of the prefab in your page with the path to the file (uploaded to the project) to be viewed.

That’s it, clicking on the prefab link at app runtime will launch the viewer.

 
We use cookies to provide you with a better experience. By using our website you agree to the use of cookies as described in our Privacy Policy.