Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
Yianni_Ververis
Employee
Employee

In every new Qlik Sense release, we see some cool additions and features that make our life easier. All of the major ones, are discussed here, https://community.qlik.com/blogs/qlikproductinnovation/2018/09/11/qlik-sense-september-2018-has-arri...‌, but for those that work a lot with the Capability Api, there are 3 very much desired and long expected features: exportData, exportImg and exportPdf. With these, you can export any embedded object from your mashup in the above formats. You can also customize them by passing the desired options.

 

Below are the links to the help files so you can experiment more.

 

ExportData

https://help.qlik.com/en-US/sense-developer/September2018/Subsystems/APIs/Content/Sense_ClientAPIs/C...

 

ExportImg

https://help.qlik.com/en-US/sense-developer/September2018/Subsystems/APIs/Content/Sense_ClientAPIs/C...

 

ExportPdf

https://help.qlik.com/en-US/sense-developer/September2018/Subsystems/APIs/Content/Sense_ClientAPIs/C...

 

You can view all of these in action by visiting the qdt-components webpage

React template with qdt-components

 

Best,

Yianni

32 Comments
royal_87
Partner - Contributor III
Partner - Contributor III

I only got ExportData to work

Like this:

app.getObject('QV01', 'MYID').then( function( vizModel ) {

      vizModel.exportData(settings).then(function( reply ) { 

          console.log(reply);

      });

  });

But the other two methods doesn't work. What do I have to change in above code to get it work?

Allso your React template is broken.

0 Likes
7,574 Views
Yianni_Ververis
Employee
Employee

Here is the code with their settings on all of the 3 methods.

https://github.com/qlik-demo-team/qdt-components/blob/master/src/components/QdtButton.jsx

7,574 Views
royal_87
Partner - Contributor III
Partner - Contributor III

Thanks for you reply Yianni!

I checked at your code and it seemed to me that all three methods are being used the same way except for different options.

If I try to log them to the console I only find exportData. Is the other two methods on a different level?

   app.getObject('QV01', 'MYID').then( function( vizModel) {

       console.log(vizModel.exportData); // returns function

       console.log(vizModel.exportPdf);   // returns undifined

       console.log(vizModel.exportImg);   // returns undifined

  });

7,574 Views
bramkn
Partner - Specialist
Partner - Specialist

Is this also available in the .NET SDK? Have been waiting for this

0 Likes
7,574 Views
jfkinspari
Partner - Specialist
Partner - Specialist

Is it possible to export an entire sheet using these methods?

0 Likes
7,574 Views
Yianni_Ververis
Employee
Employee

Hello Jens

This methods are bind just to an object's model

0 Likes
7,574 Views
Yianni_Ververis
Employee
Employee

Hello Roy,

Check your server TempDirectory if the files are created. It could be permission issues

C:\ProgramData\Qlik\Sense\Repository\TempContent

Also check your security rules if the anon users can exportApp contents

0 Likes
6,725 Views
Yianni_Ververis
Employee
Employee

Thank you Roy, The url to the export data is wrong. It has qdt-components in... fixing...

0 Likes
6,725 Views
jfkinspari
Partner - Specialist
Partner - Specialist

Within the Qlik Sense App Ui, you can choose to export a sheet as PDF. Can that be triggered using API?

6,725 Views
Yianni_Ververis
Employee
Employee

Roy,

I just fixed the buttons. Csv, jpg and pdf should be fine now

Thnx

Yianni

6,725 Views