COBCH1631 ATTACH and DETACH statements can only be applied to events

You can only use the attach or detach syntax on delegate fields that have the event keyword specified.

See the Events section of Delegates and Events for more information.