Formua Agent @setfield not working

Hi,Using Notes 8.5.3FP3

I’ve writen many agents in the past and don’t know why this is happening or if my brain has just stopped working.

I’m writing a simple formula agent that acts on “Select documents in view”.

I’m trying to do a simple

@setfield(“FIELDNAME”;“new value”);

The agent runs but doesn’t save a value.

Subject: Obvious questions

You are putting the field name in quotes?Your select statement isn’t excluding all documents?

Subject: reply

Hi,The select statement is SELECT @All

The field name is in quotes.

Subject: And it’s a one line agent?

If so, what happens if you just put FIELD fieldname:=value;

If it’s more than one line, can you post the whole code?