Check how many time a file was accessed

Check how many time a file was accessed

  

Good day.

I am very new to Outsystems. I created a web application where the user can upload a document. What i would like to know is, is their a way to show when the document was uploaded like a date function, and if possible how many times the document was accessed.


Any help would be appreciated

Hi David.

To give you more flexibility, the best way is to create your own Log entity and create a record anytime you want to log information about a download or a file view.

Cheers,

GM 

Gonçalo Martins wrote:

Hi David.

To give you more flexibility, the best way is to create your own Log entity and create a record anytime you want to log information about a download or a file view.

Cheers,

GM 

Thank for the speedy reply i really do appreciate it

 


Solution

Hi David,

To register when a document was uploaded (and by whom), it is customary to have a "CreatedOn" and a "CreatedBy" Attribute in your Entity. When saving the record, use CurrDateTime() for "CreatedOn" and GetUserId() for "CreatedBy".

As for logging the access to the document, Gonçalo's idea of a log table is a good one, though it might be overkill if you just need the number of accesses instead of also who accessed it and when they accessed it.

Solution