Download button on dashboard not working

0
Hi,I created a dashboard on mendix, and added a download button there to export the dashboard as a PDF. On studio pro, I used the document generation marketplace module, and added a microflow with a seperate pdf page. But when I'm trying to download it on mendix it gives an error saying contact system administration. When i checked the logs locally it shows the issue it with some files in the marketplae moduled, which even after editing give the same output. Did anyone ever face a simmilar issue?
asked
2 answers
1

Hi Nerav,


Yes. This usually happens due to permissions or file storage issues in the Document Generation module. Check that:

  • The Document Generation module roles are assigned to the user.
  • The FileDocument entity permissions are correct.
  • The app has write access to the file storage (especially in local vs deployed environments).
  • The Document Generation module version is compatible with your Mendix version.

Re‑importing the module alone won’t fix it unless the security and file permissions are corrected.


answered
0

Hi,


This kind of issue with the Document Generation module usually comes down to either access rights or file handling configuration, not the button itself.

Since you’re seeing “contact system administration” and logs show errors in the module, check the following step by step:

1. Check entity access

The generated PDF is typically stored in a FileDocument entity.

Make sure:

  • User role has read/write access to the FileDocument (or your custom specialization)
  • Access to the entity used in Document Generation (e.g. GeneratedDocument) is allowed

If the user cannot read the file → download will fail.

2. Verify microflow logic

In your download microflow:

  • Ensure you are using:
Generate document → Store in FileDocument → Download file

  • After generation:
    • Commit the FileDocument
    • Then call Download file activity

Missing commit is a common issue.

3. Check Document Template & placeholders

If logs mention file/template errors:

  • Open your Document Template
  • Verify:
    • All attributes exist
    • No broken references
    • Correct associations used

Even a small mismatch can break PDF generation.

4. Check module dependencies

Make sure:

  • Document Generation module is latest compatible version
  • All required modules (like Community Commons if used) are installed

Older versions often throw runtime errors.

5. Look at logs (important)

Set log levels:

  • DocumentGeneration → DEBUG
  • ConnectionBus → DEBUG

Check for:

  • Template processing errors
  • File creation failures

6. Test with Admin user

Run the same action as Admin:

  • If it works → definitely access/security issue
  • If it fails → configuration/template issue

7. Environment-specific issue

If it works locally but not elsewhere:

  • Check file storage (disk/S3)
  • Check permissions in environment

This is typically caused by either:

  • Missing entity access to FileDocument, or
  • Incorrect document generation flow (especially commit before download)

Fixing these usually resolves the issue without changes to the button or UI.



answered