Functions Core
A
AAdd()
Add a new element to the end of an array
Abs()
Return the absolute value of a numeric expression
AChoice()
Execute a pop-up menu
AClone()
Duplicate a nested or multidimensional array
ACopy()
Copy elements from one array to another
ACos()
Calculate the arc cosine in radians
ADel()
Delete an array element
ADir()
Fill a series of arrays with directory information
AEval()
Execute a code block for each element in an array
AFill()
Fill an array with a specified value
AfterAtNum()
Return the portion of a string after the nth occurrence of a substring
AIns()
Insert a NIL element into an array
Alert()
Display a simple modal dialog box
AllTrim()
Remove leading and trailing spaces from a character string
AltD()
Invoke the xDev debugger
AParams()
Return all arguments passed to the current routine
ArgC()
Return the number of command-line arguments
ArgV()
Return one command-line argument
Array()
Create an uninitialized array of specified length
ArrayBlock()
Create a set/get code block for an array element
ArrayId()
Return the identity of an array or object
Asc()
Convert a character to its ASCII value
AScan()
Scan an array for a value or until a block returns true ( .T. )
ASin()
Calculate the arc sine in radians
ASize()
Grow or shrink an array
ASort()
Sort an array
At()
Return the position of a substring within a character string
AtAdjust()
Move a selected substring to a specified byte position
ATail()
Return the highest numbered element of an array
ATan()
Calculate the arc tangent in radians
Atn2()
Calculate the arc tangent from Cartesian coordinates
AtNum()
Search multiple occurrences of a substring within a string
AtRepl()
Replace occurrences of a byte sequence in a string
AtSkipStrings()
Find a byte sequence outside quoted parts of a string
AtToken()
Return the position of the n-th token in a string
B
BeforAtNum()
Extract the part of a string before the last occurrence of a search string
BitRotate()
Rotate the bits of an integer; a positive nRotate rotates to the left, a negative one to the right
Blank()
Return an empty value for the data types A, C, D, L, M and N
BoM()
Return the date of the first day of a month
BoQ()
Return the date of the first day of a quarter
BoY()
Return the date of the first day of a year
BuildDate()
Return the date and time when the xDev runtime was built
C
Ceiling()
Round a number toward positive infinity
Celsius()
Convert degrees Fahrenheit to Celsius
Center()
Return a string for centered display
CharAdd()
Create a string from the sum of ASCII codes of two strings
CharAND()
Combine the characters of two strings with a binary AND
CharEven()
Extract the characters at even positions from a string
CharHist()
Create a histogram of the characters in a string
CharList()
Remove duplicate characters from a string
CharMirr()
Reverse the order of the characters in a string
CharMix()
Merge the characters of two strings
CharNoList()
Return a string of all characters not included in a string
CharNOT()
Invert the bits of the characters in a string with a binary NOT
CharOdd()
Extract the characters at odd positions from a string
CharOne()
Remove duplicate adjacent characters from a string
CharOnly()
Remove all characters but the specified ones from a string
CharOR()
Combine the characters of two strings with a binary OR
CharPack()
Compress a string
CharRela()
Test if two substrings in two strings have the same position
CharRelRep()
Replace characters if two substrings in two strings have the same position
CharRem()
Delete specified characters from a string
CharRepl()
Replace a list of characters with a corresponding list
CharRLL()
Rotate the bits of the characters in a string to the left
CharRLR()
Rotate the bits of the characters in a string to the right
CharSHL()
Shift the bits of the characters in a string to the left
CharSHR()
Shift the bits of the characters in a string to the right
CharSList()
Remove duplicate characters from a string and sort the result
CharSort()
Sort characters or character sequences within a string
CharSpread()
Format a character string for block paragraphs
CharSub()
Create a string by subtracting the ASCII codes of two strings
CharSwap()
Exchange adjacent characters in a string
CharUnpack()
Uncompress a string compressed with CharPack()
CharWin()
Replace characters in a screen area
CharXOR()
Combine the characters of two strings with a binary XOR
CheckSum()
Calculate the classic xBase 32-bit checksum
Chr()
Return a single byte from its numeric code
ClearEol()
Clear a row on the screen from a specified position
ClearWin()
Clear all or part of the screen
ClEol()
Clear the characters and colors in a row on the screen
ClrArea()
Give an area of the screen one color
ClWin()
Clear the characters and colors in a screen area
CmdArgArgV()
Return the program name as it was started
ColorIndex()
Return one color value of a color string
ColorToN()
Convert a color string to a numeric color attribute
ColorWin()
Replace a color attribute in a screen area
Compiler()
Return the C compiler that built the xDev runtime
Complement()
Create the complement of a value of type C, D, L, M or N
Cos()
Calculate the cosine of an angle in radians
CosH()
Calculate the hyperbolic cosine
Cot()
Calculate the cotangent
CountLeft()
Count a specified character on the left side of a string
CountRight()
Count a specified character on the right side of a string
CRC32()
Calculate the standard CRC-32/ISO-HDLC checksum
CToBit()
Convert a character string to an integer based on a bit pattern
CToDoW()
Return the number of a week day from its name
CToMonth()
Return the number of a month from its name
CToN()
Convert a string of digits to an integer of the specified base
D
Days()
Calculate the number of days from elapsed seconds
DaysInMonth()
Return the number of days in a month
DaysToMonth()
Return the number of days from the first of January to the beginning of a month
Default()
Give a variable a default value when it holds NIL
DefPath()
Return the SET DEFAULT directory with a separator at the end
DeleteFile()
Delete a file with error handling
DirName()
Return the current directory
DiskFree()
Return the free storage space of a disk drive in bytes
DiskTotal()
Return the total storage space of a disk drive in bytes
DiskUsed()
Return the used storage space of a disk drive in bytes
DMY()
Format a date as "dd. Month yyyy"
DoY()
Return the day number of a date in its year
DToR()
Convert degrees to radians
E
ElapTime()
Calculate the time elapsed between a start and an end time
Enhanced()
Select the enhanced color of SetColor()
Eol()
Return the end of line of the system or the one used in a text
EoM()
Return the date of the last day of a month
EoQ()
Return the date of the last day of a quarter
EoY()
Return the date of the last day of a year
Error
Describe a runtime error
ExeName()
Return the executable file name of the application
Expand()
Insert characters between all characters of a string
Exponent()
Calculate the exponent of a floating point number
F
Fact()
Calculate the factorial of a number
Fahrenheit()
Convert degrees Celsius to Fahrenheit
FCharCount()
Count non-whitespace bytes in a file
FClose()
Close a caller-owned numeric file handle using the classic xBase API
FCommit()
Flush pending writes on a numeric file handle
FCreate()
Create a file or truncate it to zero bytes
FError()
Read the status of the last file operation
FileAppend()
Append the contents of one file to another
FileAttr()
Return the attributes of a file
FileClose()
Close a shared managed file resource
FileCommit()
Flush pending writes on a managed file resource
FileDate()
Return the date of a file
FileDelete()
Delete files specified by a file mask and file attributes
FileError()
Read the last file-operation status
FileHandleEof()
Test EOF without moving a numeric file cursor
FileOpen()
Open an existing file as a managed resource
FileParse()
Read a CSV file into records, supporting delimiters and CR/LF bytes inside quoted fields
FileRead()
Read bytes into an existing string buffer
FileReadIni()
Read UTF-8 INI configuration into hashes
FileSeek()
Set the byte position of a managed file
FileSetIniComment()
Set program-wide INI comment markers for FileReadIni() and FileWriteIni()
FileSize()
Query a file size without changing a managed resource cursor
FileStats()
Read a single file metadata snapshot without loading its contents
FileStr()
Read a string from a file beginning at a specified offset
FileTemp()
Create and open a temporary file
FileTextEof()
Test whether the selected text area is closed, empty or positioned past its last physical line
FileTextGoBottom()
Position the selected text area at its final physical line
FileTextGoto()
Position the selected text area at nLine, counted from 1
FileTextGoTop()
Position the selected text area at its first physical line
FileTextInfo()
Return six fields for the selected text area: area number, physical line count, current line number, zero-based byte offset of the current line, file size in bytes and EOF flag
FileTextLastRec()
Return the indexed physical line count in the selected text area without moving the current record
FileTextReadAndSkip()
Read a logical CSV record and advance beyond it
FileTextReadLn()
Read the current physical line without moving the record position
FileTextRecNo()
Return the current physical line number in the selected text area
FileTextSelect()
Select a text file area from 1 to 10, independently of RDD database areas
FileTextSkip()
Move the selected text area by a signed number of physical lines, default 1
FileTextUse()
Open or close the selected text file area
FileTime()
Return the change time of a file
FileValid()
Test if a string contains a valid file name
FileWrite()
Write bytes from a string to a managed file
FileWriteIni()
Write UTF-8 INI configuration with LF line endings
FLineCount()
Count lines in a file
Floor()
Round a number toward negative infinity
FNameMerge()
Join a path, file name and extension
FOpen()
Open an existing file and return its numeric handle
FParseLine()
Parse one CSV record
FRead()
Read bytes into a preallocated string
FReadLine()
Read the next line or bounded piece of a long line
FSeek()
Move the byte position of a numeric file handle
FTempCreate()
Create a unique temporary file opened for reading and writing
FV()
Calculate the future value of constant, periodic investments
FWordCount()
Count words in a file
FWrite()
Write bytes or set the file length at the current position
G
GetClearA()
Return the default color attribute for clearing the screen
GetClearB()
Return the default character for clearing the screen
GetClrBack()
Return the background color of a color value
GetClrFore()
Return the foreground color of a color value
GetClrPair()
Extract a color value from a color string
GetPairLen()
Return the length of a color value within a color string
GetPairPos()
Return the absolute position of a color value in a color string
GetPrec()
Return the computing precision for trigonometric functions
H
I
IIF()
Return one of two values according to a logical condition
InvertAttr()
Exchange the foreground and background color
InvertWin()
Exchange the foreground and background color on the screen
IsAffirm()
Test whether an answer means "yes"
IsAlNum()
Check if the first character of a string is alpha-numeric
IsAscii()
Check if the first character of a string is a 7-bit ASCII character
IsCntrl()
Check if the first character of a string is a control character
IsDefColor()
Check if the default color is set
IsDir()
Test whether a name or a mask finds a directory
IsDirectory()
Test whether a name or a mask finds a directory
IsDisk()
Test whether a drive letter is a drive of the system
IsGraph()
Check if the first character of a string is a 7-bit graphical ASCII character
IsLeap()
Check if a Date value belongs to a leap year
IsNegative()
Test whether an answer means "no"
IsPrint()
Check if the first character of a string is a printable 7-bit ASCII character
IsPunct()
Check if the first character of a string is a punctuation character
IsSpace()
Check if the first character of a string is a white-space character
IsXDigit()
Check if the first character of a string is a hexadecimal digit
J
K
L
LastDayOM()
Return the number of days in a month
LenNum()
Return the unpadded display length of a number
Log10()
Calculate the base-10 logarithm
LToC()
Convert a logical value to a character
LToN()
Convert a logical value to a numeric value
M
Mantissa()
Calculate the mantissa of a floating point number
MaxLine()
Return the byte length of the longest text line
MD5()
Calculate a message digest for a stream of data using the MD5 algorithm
MD5File()
Calculate a message digest for a file using the MD5 algorithm
MDY()
Format a date as "Month dd, yy"
MilliSec()
Define a time delay in milliseconds
MilliSeconds()
Return the current UTC time as a Julian timestamp in milliseconds
ModuleCall()
Call a function of a module loaded by ModuleLoad()
ModuleLoad()
Load a DLL module and run its INIT procedures
ModuleUnload()
Run the EXIT procedures of a module and free it
N
NationMsg()
Return a message of the national language
NToC()
Convert an integer to a string of digits for a specified number base
NToCDoW()
Convert a numeric week day to its name
NToCMonth()
Convert a numeric month to its name
NToColor()
Convert a numeric color attribute to a color string
NumAt()
Count multiple occurrences of a substring within a string
NumButtons()
Return the number of mouse buttons
NumCount()
Read, set or increment a shared integer counter
NumHigh()
Return the high byte of an unsigned 16-bit integer
NumLine()
Count text lines after fixed-width byte wrapping
NumLow()
Return the low byte of an unsigned 16-bit integer
NumMirr()
Reverse the low 8 or 16 bits of a 16-bit integer
NumMirrX()
Reverse a selected number of low bits of a 32-bit integer
NumToken()
Return the number of tokens in a string
O
Occurs()
Count the occurrences of a substring, also those that overlap
OsDriveSeparator()
Return the character that ends the drive in a path
OsNewLine()
Return the end of line of the operating system
OsPathDelimiters()
Return the characters that delimit the parts of a path
OsPathListSeparator()
Return the character that separates the paths in a list of paths
P
PadLeft()
Pad a character string on the left
PadRight()
Pad a character string on the right
Payment()
Calculate a periodical payment for loans
PCount()
Return the number of arguments passed to the current routine
Periods()
Calculate the duration for paying back a loan at fixed interest rate and payments
Pi()
Return the mathematical constant pi
PosAlpha()
Return the position of the first alphabetic characters in a character string
PosChar()
Replace a single character at a specified position in a string
PosDel()
Delete character(s) at a specified position in a string
PosDiff()
Search the first position where two character strings differ
PosEqual()
Search the first position where two character strings are equal
PosIns()
Insert character(s) at a specified position in a string
PosLower()
Return the position of the first lower case letter in a character string
PosRange()
Retrieve the position of the first character out of a range found in a string
PosRepl()
Replace characters in a string beginning at a specified position
PosUpper()
Return the position of the first upper case letter in a character string
ProcLine()
Return the source line number of a call in the call stack
ProcName()
Return the name of a procedure or function in the call stack
PV()
Calculate the present value of future capital, based on periodic investments
Q
R
RangeRem()
Delete character(s) within a specified range of characters
RangeRepl()
Replace character(s) within a specified range of characters
RAScan()
Search an array from a starting position towards the first element
Rate()
Calculate the interest rate for a loan
ReadLine()
Locate the next line inside a string without allocating a file or changing input
RemAll()
Delete a specified character from both sides of a string
RemLeft()
Delete a specified character from the left side of a string
RemRight()
Delete a specified character from the right side of a string
RenameFile()
Rename a file and handle errors
ReplAll()
Replace a specified character on both sides of a string
ReplLeft()
Replace a specified character on the left side of a string
ReplRight()
Replace a specified character on the right side of a string
RestToken()
Restore the global environment of the incremental tokenizer
RToD()
Convert radians to degrees
S
SaveToken()
Save the global environment of the incremental tokenizer
SClone()
Duplicate a structure
ScreenAttr()
Return the numeric color attribute for a specified coordinate on the screen
SecondsCPU()
Return the CPU time used by the current process
SecondsSleep()
Suspend thread execution for a number of seconds
Secs()
Calculate the number of seconds from a time string
SecToTime()
Convert numeric seconds into a time formatted character string
SetClearA()
Set the default color attribute for clearing the screen
SetClearB()
Set the default character attribute for clearing the screen
SetClrPair()
Replace a color value in a color string
SetColor()
Return the current colors and optionally set new colors
SetFAttr()
Set file attributes
SetFDaTi()
Set the last change date and time of a file
SetKeyArray()
Give one action to several keys
SetKeyCheck()
Run the action of a key
SetKeyGet()
Return the action and the condition of a key
SetKeySave()
Return all SetKey() assignments and optionally replace them
SetPosBS()
Move the cursor one column to the right
SetPrec()
Specify the computing precision for trigonometric functions
Sign()
Convert the sign of a number to a numeric value
Sin()
Calculate the sine of an angle in radians
SinH()
Calculate the hyperbolic sine
Standard()
Select the standard color of SetColor()
SToD()
Convert a YYYYMMDD string to a date
StrDel()
Delete bytes selected by a position mask
StrDiff()
Calculate the similarity of two strings
StrFile()
Write a string to a file starting at a specified position
StringToLiteral()
Represent a byte string as an xDev source expression
StrIsUTF8()
Check whether an entire character string contains well-formed UTF-8
StrPeek()
Read the unsigned byte value at a string position
StrPoke()
Replace one byte in a string
StrSwap()
Exchange characters between two strings
T
TabExpand()
Replace a tab with a specified number of another character
TabPack()
Insert a Tab (Chr(9)) for multiple occurrances of a character
Tan()
Calculate the tangent of an angle in radians
TanH()
Calculate the hyperbolic tangent
TimeToSec()
Calculate the number of seconds since midnight
TimeValid()
Check if a character string is a valid time string
Token()
Retrieve the n-th token from a string
TokenAt()
Return the start and end position of a token
TokenEnd()
Test if tokens can still be found with TokenNext()
TokenExit()
Release memory resources of the global tokenizer environment
TokenInit()
Initialize the environment for the incremental tokenizer
TokenLower()
Change the first character of tokens to lower case
TokenNext()
Retrieve the next token from a string
TokenNum()
Return the number of tokens in a tokenizer environment
TokenSep()
Retrieve the separating characters of a token
TokenUpper()
Change the first character of tokens to upper case
Transform()
Convert any value into a formatted character string
TrueName()
Complete a relative path to include the root directory
TString()
Convert numeric seconds into a time formatted character string
U
UChars()
of its own, and so is every invalid byte, kept unchanged like in USubStr()
Unselected()
Select the unselected color of SetColor()
Unused()
Mark variables and parameters that are not used on purpose
UPeek()
Read the Unicode scalar value at a character position in a UTF-8 string
UPoke()
Replace one UTF-8 character with a specified Unicode scalar value
URAt()
Find the last occurrence of a substring using UTF-8 character positions
UTF8Asc()
Return the Unicode scalar value of the first UTF-8 character
UTF8Chr()
Encode a Unicode scalar value as one UTF-8 character
UUDecode()
Decode and validate a complete UUencode body or file envelope
UUDecodeFile()
Decode a UUencoded file to an explicit destination
UUEncode()
Encode bytes as a complete UUencode data body
UUEncodeFile()
Encode a binary file in a UUencode envelope