HP3000-L Archives

January 2003, Week 4

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
"VANCE,JEFF (HP-Cupertino,ex1)" <[log in to unmask]>
Reply To:
VANCE,JEFF (HP-Cupertino,ex1)
Date:
Tue, 28 Jan 2003 16:10:32 -0500
Content-Type:
text/plain
Parts/Attachments:
text/plain (25 lines)
ooops, correction in my abbreviated WHILE loop below:

...
> setvar if_printer false
> while not if_printer and &
>       setvar(_sp_eof,_sp_eof-1) >= 0 &
>       "!ldevno" <> word(setvar(_sp_rec,dwns(input()))) do
  endwhile
# We have an LDEV match or we hit eof
  if _sp_eof >= 0 and &
     pos('spooled',_sp_rec) > 0 and pos('down',_sp_rec) = 0 then
>    echo Printer found number: !ldevno
>    setvar if_printer true
> endif

I moved the endwhile up and thus the WHILE loop has no body.
You don't need to read anymore SHOWDEV records once you find
the matching LDEV number, even if the LDEV is DOWN or is
not SPOOLed.

 Jeff

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

ATOM RSS1 RSS2