num-var = Get_LNum(line-ptr)


Operands:

line-ptr

the specific line-ptr for which the line number is desired.


Returns:


If the line-ptr is valid, the associated external line number is returned; RC is set to 0 and Msg$ set to "" (null)


If the line-ptr is invalid, "" (null) is returned,  RC is set to 8, and Msg$ is set to an error message.


Special Notes:


Only data lines have line numbers, so if you attempt to use Get_LNum$ using a line-ptr value for which a call to IS_DATA(line-ptr) would have returned False, the call to GET_LNUM$(line-ptr) will with RC=8 and a returned value of 0.


Assuming the edit session is not operating in Fast Renumber mode, the line number of the last line of the file, and the number of lines in the file, are the same number; call this number N. If you call Get_LNUM with an LPTR value <= 1 or > N+2, the Line Pointer parameter is out of range, and Get_LNUM will return 0.


Created with the Personal Edition of HelpNDoc: Free help authoring environment