Download file Base64

Hello everyone!

I saved my files (pictures, excel, word) in my database with encoding base64.
Is there any way that I can recreate my files and then download them?

http://documentation.xojo.com/api/text/encoding_text/decodebase64.html to recreate your files in memory.
http://documentation.xojo.com/api/web/webfile.html to create an object to download.

Thank you Mr Louis for your reply!

Everything is fine now. I noticed that I had to define the WebFile as a property of the WebPage and not as a local variable.

Your webfile instance has to stay available during all processes, it can be defined at WebPage or Session level.
Local variable are usually not an option.

I would suggest to use BLOB fields and not use Base64 to store data in field.

Thank you Mr Christian for your advice.

Why BLOB fields and not Base64?

BLOB field without Base64 is 30% smaller than text field with Base64 encoded data.