Columns in tables displaying images can trigger action events, when the user selects the image.
The following example defines a TABLE with two IMAGE columns, and attaches the update and delete actions:
LAYOUT
TABLE
{
[c1 |c2 |i1|i2]
[c1 |c2 |i1|i2]
[c1 |c2 |i1|i2]
}
END
END
ATTRIBUTES
EDIT c1 = FORMONLY.id, TITLE="Id", NOENTRY;
EDIT c2 = FORMONLY.name, TITLE="Name";
IMAGE i1 = FORMONLY.i_modify, ACTION=update;
IMAGE i2 = FORMONLY.i_delete, ACTION=delete;
END
INSTRUCTIONS
SCREEN RECORD sr(FORMONLY.*);
END
DISPLAY ARRAY arr TO sr.*
ON UPDATE
-- user code
ON DELETE
-- use code
END DISPLAY