0

My application is generating excel and pdf reports. They are generated in Uint8list. Is there a way to open such files in default application?

I tried open_file package, however, it requires a file path while my file is in memory. same with url_launcher.

Also I tried saving the file then using open_file, but it doesn't work on web as file can't be saved.

Elie Saad
  • 516
  • 4
  • 8
  • Well you can use [file_saver](https://pub.dev/packages/file_saver) for web or refer to this for various methods of saving file on web [stackoverflow](https://stackoverflow.com/questions/59663377/how-to-save-and-download-text-file-in-flutter-web-application) – Frank nike Mar 11 '22 at 20:43

1 Answers1

0

I solved the issue by using printing.dat package. it has a PdfPreview that takes Uin8list and shows a preview with so many other options.

Elie Saad
  • 516
  • 4
  • 8