Table data on streamlit facing problem on download as pdf

Hi @kush_shukla

Looking through your code, it seems you have not defined mime parameter in the st.download_button. Please refer to the following example code snippet:

import streamlit as st

with open("dummy.pdf", "rb") as pdf_file:
    PDFbyte = pdf_file.read()

st.download_button(label="Export_Report",
                    data=PDFbyte,
                    file_name="test.pdf",
                    mime='application/octet-stream')

The above snippet is from this forum post: Download PDF option - #2 by andfanilo