x

MODIFYING AND OLD EMBARCADERO XE6 PROJECT


DON'T DO THIS





 

DO THIS INSTEAD

IF YOU PRESSED PAUSE, YOU WILL GO INTO A DEBUG MODE

IF YOU PRESSED PAUSE, YOU CAN CHECK THE VALUES OF ANY VARIABLE SUCH AS THE LEFT EDGE OF THE FORM

IF YOU PRESSED PAUSE, YOU CAN CHECK THE VALUES OF ANY VARIABLE SUCH AS THE TOP EDGE OF THE FORM

BACK TO YOUR SOURCE CODE (Unit1.cpp)

A DIGRESSION REGARDING FUNCTIONS

You can add functions to make your code more dynamic and flexible.
A function is also an agent with an STA architecture:
It senses its environment (listens to be callse). It thinks (processes information internally). It acts (changes its environment or returns a value).

A functions may:
Take one or more parameters (listen for information when they are called).
Return a single value (answer back to whoever called them).
The type of information they take or return is specified (int, bool, float).
Any information they do not take or return is specified (void).


Make the ButtonRedClick event call a function named "red" which will take no parameters (void) and return no value (void).

Make the ButtonRedClick event call a function named "red" which will take no parameters (void) and return a single value (bool).

Make the ButtonRedClick event call a function named "red" which will take one parameter (int) and return one value (bool).

CENTERING YOUR PROGRAM IN THE DISPLAY

AS YOU DID BEFORE:

SAVE ALL (of the project)

CLOSE ALL (projects)

EXIT (Embarcadero)