{{fbdoc item="title" value="LPOS"}}----
Returns the number of characters sent to the printer port in the last ##[[KeyPgLprint Lprint]]## statement.

{{fbdoc item="syntax"}}##
	[[KeyPgDeclare declare]] [[KeyPgFunction function]] **Lpos** ( [[KeyPgByval byval]] //printer// [[KeyPgAs as]] [[KeyPgLong long]] ) [[KeyPgAs as]] [[KeyPgLong long]]
##
{{fbdoc item="usage"}}##
	//result// = LPOS(//printer//)
##
{{fbdoc item="param"}}
	##//printer//##
		Either 0, 1, 2 or 3.  Represents the printer port (LPT#)

{{fbdoc item="ret"}}
	Returns the number of characters sent.

{{fbdoc item="desc"}}
	Used to determine, from the last ##[[KeyPgLprint Lprint]]##, how many characters were sent to the printer port.

{{fbdoc item="ex"}}
{{fbdoc item="filename" value="examples/manual/hardware/lpos.bas"}}%%(freebasic)
' compile with -lang fblite or qb

#lang "fblite"

Dim test As String = "LPrint Example test"

Print "Sending '" + test + "' to LPT1 (default)"
LPrint test
Print "LPT1 last recieved " + Str(LPOS(1)) + " characters"
Print "String sent was " + Str(Len(test)) + " characters long"

Sleep
%%

{{fbdoc item="diff"}}
	- None

{{fbdoc item="see"}}
	- ##[[KeyPgLprint Lprint]]##

{{fbdoc item="back" value="CatPgMisc|Miscellaneous"}}