GeromeRich
5 years agoQrew Trainee
Record who presses a URL Button
Hi,
We are using QB as a Knowledge Hub, uploading documents from our various projects and programmes. The documents are our companies IP.
Accordingly we want to be able to track who is downloading the documents as we do occassionally give access to contractors.
To cover off on access restrictions we don't display the file attachment in records or reports for general users. I have a URL Button that tests that a <Restricted Access> checkbox is not ticked, and that a document actually exists. If these two criteria are met, the button appears and is able to be pressed which downloads the document.
Code for the button is here:
If([Restricted Access]=false,If(ToText([Attachment])<>"",
URLRoot() & "up/" & Dbid() & "/a/r" & [Record ID#] & "/e6/v0"))
What I would like to be able to do is each time the button is pressed, record the user pressing the button in a log field. Date and time would be a bonus, but could live with just user name.
Basically just need to copy Current User and potentially date to a text field, that has the <log> button ticked!
Any help greatly appreciated in how we add this to the URL if it is even possible at all.
Cheers
------------------------------
Gerome
------------------------------
We are using QB as a Knowledge Hub, uploading documents from our various projects and programmes. The documents are our companies IP.
Accordingly we want to be able to track who is downloading the documents as we do occassionally give access to contractors.
To cover off on access restrictions we don't display the file attachment in records or reports for general users. I have a URL Button that tests that a <Restricted Access> checkbox is not ticked, and that a document actually exists. If these two criteria are met, the button appears and is able to be pressed which downloads the document.
Code for the button is here:
If([Restricted Access]=false,If(ToText([Attachment])<>"",
URLRoot() & "up/" & Dbid() & "/a/r" & [Record ID#] & "/e6/v0"))
What I would like to be able to do is each time the button is pressed, record the user pressing the button in a log field. Date and time would be a bonus, but could live with just user name.
Basically just need to copy Current User and potentially date to a text field, that has the <log> button ticked!
Any help greatly appreciated in how we add this to the URL if it is even possible at all.
Cheers
------------------------------
Gerome
------------------------------