Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- CA-Clipper Tools . Books 1-3 - <b>valpos()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 VALPOS()
 Determines the numerical value of the character at a particular position
------------------------------------------------------------------------------
 Syntax

     VALPOS(<cString>,[<nPosition>]) --> nAsciiValue

 Arguments

     <cString>  Designates any string.

     <nPosition>  Designates which character to convert into numeric data
     format.  The default value processes the last character.

 Returns

     VALPOS() returns the numeric value of the character at <nPosition>.

 Description

     VALPOS() converts a particular character in a string to its numerical
     equivalent.  You do not have to nest functions if you use VALPOS().

 Notes

     .  This function works a bit differently than the CA-Clipper
        VAL() function.  VAL() terminates the conversion when a non-numeric
        character appears.  VALPOS() only processes a single character.

     .  If <nPosition> is past the end of <cString>, or the character
        selected through <nPosition> is not a number, VALPOS() returns 0.

 Example

     Determine the value of the character at position 3:

     cString  :=  "AX4B"
     ? VALPOS(cString, 3)      // Result: 4


See Also: ASCPOS()

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