Print document saved on server

0

I am creating a web page where users can upload files ( exel or word ) and save them in a SQL server and then others can see those files and have the possibility to print them. The truth is that I am having problems to create a method that allows printing. Is there any way? Thanks.

I have all the code to upload and download the files so it would be a bit tedious to copy the entire file. To download the files I basically use the DownloadFromDatabase (File) method or to upload them use SQL (INSERT ...) and then ExcecuteQuery ().

Then the question would be simply which method / command exists to print the files or explain a small example.

Thank you.

    
asked by user5673573 18.03.2018 в 16:32
source

1 answer

0

For excel or word 2003+ you must use Open XML SDK or special libraries like devexpress to be able to "print" without "downloading" them (the relial is that you download them but print them without consulting and they remain in the temp with a strange name) .

Without using devexpress style libraries you will not be able to print directly word or excel since being files of special types, it is the browser that decides what is done with this file, therefore you will have to manipulate the file as xml and do all the processes at hand.

here there is an answer in English

    
answered by 18.03.2018 в 23:41