passing data to functions in other units
From: Kris Leech (krisleech_at_email.com)
Date: 08/31/04
- Next message: Bruce Roberts: "Re: passing data to functions in other units"
- Previous message: Kris Leech: "Re: if EthType < StrToInt('$05DC') then EthType := 0; // does'nt work!!"
- Next in thread: Bruce Roberts: "Re: passing data to functions in other units"
- Reply: Bruce Roberts: "Re: passing data to functions in other units"
- Reply: J French: "Re: passing data to functions in other units"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Tue, 31 Aug 2004 16:12:24 +0000 (UTC)
Hi ya, The program i am writing has got very long and i want to break it
up in to units to make it more readable/maintainable.
My main unit will then call functions in other units. This is fine
expect that currently my main unit does not pass variables to the
functions it calls, instead they all work on a global variable.
Once my functions are in other units that global variable is no longer
available. What is the best way to get the variable to the functions in
the other units.
I assume i can either pass the whole variable to the functions (which
may be slow?) or pass a pointer to the global variable??
The global variable i have is a static array of bytes.
Thanks for any help or pointers ;)
Kris.
- Next message: Bruce Roberts: "Re: passing data to functions in other units"
- Previous message: Kris Leech: "Re: if EthType < StrToInt('$05DC') then EthType := 0; // does'nt work!!"
- Next in thread: Bruce Roberts: "Re: passing data to functions in other units"
- Reply: Bruce Roberts: "Re: passing data to functions in other units"
- Reply: J French: "Re: passing data to functions in other units"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|