Sys(2600)
If you have experience with other programming languages, you might be familiar with the peek/poke concept. If you're not familiar with peek/poke, you'll be happy to know that it has nothing to do with looking at pigs in a sack (peeking at pigs in a poke? Oh, never mind). It means that you can look at a specific memory location (peek), or put a value into a specific location in memory (poke). Finally, beginning in VFP 7, we have the ability to manipulate memory directly.
Usage |
cContents = SYS( 2600, nAddress, nNumberOfBytes [ , cValueToPoke ] ) |
Parameter |
Value |
Meaning |
nAddress |
Numeric |
The address of the location in memory. |
nNumberOfBytes |
Numeric |
How many bytes to return/write. |
cValueToPoke |
Omitted |
Return the value in the specified location in memory (peek). |
Character |
"Poke" the value into the specified location in memory. |
|
cContents |
Character |
The value in memory. |
Example |
* Because you can really hose your system, we won't give an * example that you can cut and paste and potentially trash your * system. Instead, we'll point you to an example shipped with * FoxPro. Execute the following, and you'll see the * code that reads memory: SELECT 0 USE HOME() + "foxcode" AGAIN SHARED LOCATE FOR Expanded = "GetEnv" MODIFY MEMO Data * And, yes, the "PROCEDURE Destory" on line 31 * really should be "Destroy". |
See Also |