Paul Shumaker Posted December 1, 2020 Share Posted December 1, 2020 Hello, I am currently trying to create an application object and open the document using JavaScript API. I am able to get a return status of OK but the analysisDocument property is always null. Does anyone know what I'm doing wrong It seems I can access the application and get an onReadyCallback, but I can't actually build the application or get any Documents out of it. Application.analysisDocument always results as null. I am using the application loader API (loader.js). var app; var doc; var rootUrl = 'http://server:8080/spotfire/wp/'; var customizationInfo = new spotfire.webPlayer.Customization(); var apiVersion = '7.5'; var analysisPath = '/Operations/HSE/HSE Insights'; var parameters; var reloadInstances = true; var onReadyCallback; var onCreateLoginElement; $(document).ready(function() { try { spotfire.webPlayer.createApplication( rootUrl, customizationInfo, analysisPath, parameters, reloadInstances, apiVersion, onReadyCallback, onCreateLoginElement ); function onReadyCallback(result, newApp) { app = newApp; window.alert(result.status); doc = app.openDocument("test"); window.alert(app.analysisDocument); } } catch(err) { window.alert(err.message); } }); Link to comment Share on other sites More sharing options...
Paul Shumaker Posted December 2, 2020 Author Share Posted December 2, 2020 I figured out the issue by looking in the console under Development Tools. It was an SSL certificate issue with accessing the loader.js. Using http:// in the import made the above code work as intended. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now