IB Statements/pcomm

From CometWiki

Jump to: navigation, search

PCOMM function

Syntax: PCOMM(partition [,EXCP=statement-label])

Discussion: The PCOMM function returns the first 255 bytes (254 data bytes plus 1 length byte) of COMMON data from a specified partition.

The partition parameter may be a string constant, a single-element string variable, a string array element, a string expression, or a string function in the format "Pnn" (where "nn" is a numeric value from "00" to "99").

Note: If the named partition has no COMMON, the PCOMM function returns a null value.

The EXCP= parameter is used to specify an exception path in case an invalid partition name is specified.


 DATA$ = PCOMM("P05",EXCP=500)

In the above example, the PCOMM function will return the first 255 bytes of COMMON data from partition "P05". This data will be stored in the string variable named DATA$ (254 data bytes and one length byte).

Personal tools