NWP, PRINTER.SYS and POSITION

Discussion about printing issues and techniques.

Moderators: Susan Smith, admin, Gabriel

Post Reply
Susan Smith
Posts: 717
Joined: Sun Aug 10, 2008 4:24 am
Location: Southern California

NWP, PRINTER.SYS and POSITION

Post by Susan Smith »

Hi folks,

I'm trying to use the POSITION feature in PRINTER.SYS. This is from PRINTER.SYS:

Code: Select all

rem	*****  NWP only Positioning In Inches e.g [POSITION](2.34,4.25)
rem     *****  -parameters indicate horizontal and then vertical positions-
PRINTER NWP [POSITION], "\Eposition="
PRINTER NWP [POSITION(hhh,vvv)], "\Eposition='hhh,vvv'"
rem hhh denotes horizontal and vvv denotes vertical
Is there a way to use a variable to specify the horizontal and vertical positions?
If I use the following, nothing prints:

Code: Select all

let vert=.900
print #prtfile:"[POSITION(.5,vert)]"&"SOME TEXT"
But if I use a literal, it works:

Code: Select all

print #prtfile:"[POSITION(.5,.900)]"&"SOME TEXT"
Can anyone tell me what I'm missing?

-- Susan
bluesfannoz
Posts: 291
Joined: Fri Jun 19, 2009 9:01 am
Location: Lawrence, Kansas
Contact:

Re: NWP, PRINTER.SYS and POSITION

Post by bluesfannoz »

Try

Code: Select all

let vert=.900
print #prtfile:"[POSITION(.5,"&STR$(vert)&")]"&"SOME TEXT"



Susan Smith wrote:Hi folks,

I'm trying to use the POSITION feature in PRINTER.SYS. This is from PRINTER.SYS:

Code: Select all

rem	*****  NWP only Positioning In Inches e.g [POSITION](2.34,4.25)
rem     *****  -parameters indicate horizontal and then vertical positions-
PRINTER NWP [POSITION], "\Eposition="
PRINTER NWP [POSITION(hhh,vvv)], "\Eposition='hhh,vvv'"
rem hhh denotes horizontal and vvv denotes vertical
Is there a way to use a variable to specify the horizontal and vertical positions?
If I use the following, nothing prints:

Code: Select all

let vert=.900
print #prtfile:"[POSITION(.5,vert)]"&"SOME TEXT"
But if I use a literal, it works:

Code: Select all

print #prtfile:"[POSITION(.5,.900)]"&"SOME TEXT"
Can anyone tell me what I'm missing?

-- Susan
Steve Koger
Computer Specialist
SEKESC-MACS Division
Susan Smith
Posts: 717
Joined: Sun Aug 10, 2008 4:24 am
Location: Southern California

Post by Susan Smith »

Thanks Steve! That did the trick.

Now back to your regular Valentine's Day programming... :wink:

-- Susan
Post Reply