• Welcome to PlanetSquires Forums.
 

... forms and other modules ...

Started by tom cone jr, December 29, 2008, 12:17:14 PM

Previous topic - Next topic

tom cone jr


This phrase appears throughout the help files.  What are "... other modules ..." and why would one want to have them in a project?   Is this term defined somewhere I've missed (perhaps in the PowerBASIC help files?).

Thanks.

-- tom

TechSupport

Hi Tom,

You can link to other modules from within FireFly. A "module" in this context is nothing more than a BASIC source code file. I name my modules with an .inc file extension.

In FireFly, you add modules two ways:

The first way is to use FireFly itself to either create a new module or load an existing module into FireFly. Using this functionality means that FireFly will parse this file during code generation to take out the sub/function, equates, types, unions, etc... and copy them to the CODEGEN*_DECLARES file in order to handle forward referencing (something that PB has half implemented in PB9).

The second way is to link directly to the source code file. This is the method that many PB'ers are used to with using DDT or their own hand written programs. In this approach you simply #INCLUDE the file. I usually put my #INCLUDE's at the beginning of my main startup Form. Actually, a better place to put your #INCLUDE's is in a simple text file called "user_includes.inc". Check out this post: http://planetsquires.com/support/index.php?topic=2075.0


tom cone jr

Thanks.

Will check out the related thread.

-- tom