Issue with Saving/Downloading PDF Files from URL

Actions & Logic

I am facing issues while implementing a functionality to save/download PDF files from a URL in my FlutterFlow app. I have tried using the following methods, but each has limitations or bugs:

What have you tried so far?
  • Custom Code:

    • I have written a custom action to download the PDF file and save it to the device. However, for newer Android versions, files saved in the app-specific directory (e.g., Android/data/[package_name]/files) are inaccessible to the user in file explorers or public storage.

    • Storing files in the Downloads folder or public storage requires advanced permissions (MANAGE_EXTERNAL_STORAGE) that are not supported directly in FlutterFlow.

    • Additionally, saving the same file with the same name again replaces the previous file, instead of saving a new copy.

  • Launch URL:

    • Using launchUrl works fine initially, but it doesn’t allow the same file to be downloaded again because it gets cached or saved incorrectly on subsequent attempts.

Did you check FlutterFlow's Documentation for this topic?
Yes
4
8 replies