The attached project below demonstrates how to set up Friend procedures inside object modules (FRM, CLS, CTL, etc.) for Windows API callback purposes. The goal of such a technique is to keep as much code as possible within the object module in order to make it as self-contained as possible and also to reduce memory consumption once the object module is unloaded. There is a possibly significant disadvantage to this approach however - the overhead of redirecting calls to procedures in an object module naturally imposes some performance penalty.
(This code has been inspired by the following post: Re: Problem with Public UDT: 'Only public user defined types......)
(This code has been inspired by the following post: Re: Problem with Public UDT: 'Only public user defined types......)