Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 2 of 2 total
Thread Creating modules
Tue, Aug 4 2015 3:31 AMPermanent Link

Jim Gallagher

I had modules working well in ewb1, and I'm pretty sure in ewb2 build1, but now my module is not working.  In XE2, if I create a new module, I get the attached error saying that the onexecute event does not exist.  I've tried uninstalling and re-installing the modules, but the error persists.  Have I bungled the install somehow?  I don't get the error with XE5, but I don't have a DBISAM license for that version, so I can't use it.

Also, a more general question:  In EWB1, if I remember right, modules were reloaded every time they were called.  If that is still the case with EWB2, is it a good practice for performance optimization to create a separate module for each function, to keep the module size small?

Thanks,

-Jim



Attachments: xe2.png
Tue, Aug 4 2015 8:52 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Jim,

<< I had modules working well in ewb1, and I'm pretty sure in ewb2 build1, but now my module is not working.  In XE2, if I create a new module, I get the attached error saying that the onexecute event does not exist.  I've tried uninstalling and re-installing the modules, but the error persists. >>

Is the EWB 2 modules design-time package installed ?  If, at any time, you tried to install the EWB 2 modules when the EWB 1 modules were already installed, then the IDE would have prevented the EWB 2 design-time package from loading and it would not get loaded after that, even if you uninstalled the EWB 1 design-time package.  To fix this, you have to go into Component/Install Packages and make sure that the EWB 2 modules design-time package is both present and checked.

<< Also, a more general question:  In EWB1, if I remember right, modules were reloaded every time they were called. >>

If, by "modules", you mean the DLLs, then no, that is not correct.  Each TEWBModule *instance* is created/loaded per call, but the DLL is only loaded once and then it stays loaded.

<< If that is still the case with EWB2, is it a good practice for performance optimization to create a separate module for each function, to keep the module size small? >>

You shouldn't adjust the functionality of a given module based upon the module/DLL size.  Just design your modules according to your needs, and you'll be all set. Performance is normally more related to things like what the module creates or opens in terms of resources (database tables, etc.).

Tim Young
Elevate Software
www.elevatesoft.com
Image