Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- NetLib for Clipper, Version 6.0 - ch_chr2( <nvalue> [, @<cmemvar> [, <nposition>] ] ) http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
CH_CHR2( <nValue> [, @<cMemvar> [, <nPosition>] ] )


Parameters

<nValue>
Value to poke.

<cMemvar>
Name of memory variable into which <nValue> should be poked.

<nPosition>
Byte position in the memory variable. The default is the first byte (1).


Returns

CH_CHR2(<nValue>) with no second parameter returns the two-byte 
representation of the specified number. It is similar to the CHR() 
function but returns two bytes instead of one.


Description

The specified number is "poked" into the character variable starting at 
the specified position (default position = 1). The number is stored in 
standard Intel low-high integer format. The variable name must be 
prefixed with @ to be updated properly. Do not attempt to store data 
beyond the end of the string.


Examples

// Store 1000 into bytes 8-9 in string
CH_CHR2(1000, @cString, 8)

// Returns two-character representation of 1000
? CH_CHR2(1000)



See Also: CH_CHR1() CH_CHR4() CH_CHR8()

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson