Free Support Forum - groupdocs.com

How to automatically download file when viewer loads


#1

How can I automatically download the file when viewing


kind regards
Divan

#2

Hello Divan,


Thank you for the request. Yes, you can download document when viewing. Simply add such JavaScript code:

$(function () {
$("#test").groupdocsViewer(“downloadDocument”);
})

This code will download the document when the page is loaded.

Best regards.

#3

thank you works 100%


Kind regards
Divan

#4

Hi Divan,


Glad to hear.

Thank you.