Hi @Lucifer, is the DataTable editable?
If not, you could just export the DataFrame. This example writes a DataFrame into a json file with a static name. Instead of using df.to_json() you can use df.to_csv() and assign your variable value as name of the file.
json
df.to_json()
df.to_csv()