QBasic 1.1: LPOS Function

Syntax

LPOS(n%)

Description / Parameter(s)

n% Indicates one of the printer ports:
  0 = LPT1, 1 = LPT1, 2 = LPT2, 3 = LPT3

Example

'This example requires a printer. LPRINT FOR i% = 1 TO 20 LPRINT i%; IF LPOS(1) >= 10 THEN LPRINT 'Begin a new line. NEXT i%