File Content Empty or not Check

1
Hi Mendix Developers,   I need to validate uploaded file whether it has content inside or not. Possible files that I have to consider are Excel, ppt, Text, Word, CSV, PDF, Zip, Outlook files. String From File Activity is not helpful, as its encoding and I cant decide whether a file such as ppt has content inside or not. Please do let me know how to achieve this validation.   Regards, Cyril
asked
1 answers
0

Hi Cyril,

 

You could check the filename extension for the correct file format.

This would work almost all of the time, unless someone changes the extension by hand, which would be rarely the case. ( cause why would you do that ;) )

 

Hope this helps!

answered