Page 1 of 1

Attachment

Posted: 07 Apr 2016
by Sebastian Haugland
Hi

I want to run a function when a attachment is added, at the moment I have solved this by adding a new button to add attachment and at the same time running my "own function".

But there is a built in event I can use to detect when a attachment is added through the "standard" button in the form?

Re: Attachment

Posted: 07 Apr 2016
by rostislav
Do this:

Code: Select all

oldOkAttach = OkAttach;
OkAttach = function () {
	console.log('my code');
	oldOkAttach();
}

Re: Attachment

Posted: 27 Feb 2017
by Sebastian Haugland
Sorry was off for a loooong time.

But I tried your code, allthough the text "my code" is written to the log i get the errror below and the attachment is not saved:

"You must specify a non-blank value for file name.