HP3000-L Archives

October 1999, Week 2

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:
TRACY PIERCE <[log in to unmask]>
Reply To:
Date:
Wed, 13 Oct 1999 14:19:06 -0400
Content-Type:
text/plain
Parts/Attachments:
text/plain (30 lines)
oops! poor testing.  THIS one works for all 4 digits...
PARM POSITIONTOINCR=4
SETVAR POS !POSITIONTOINCR
SETVAR CURRVALUE STR ( MYCOUNTER , POS , 1 )
IF  "!CURRVALUE" = "Z"
  SETVAR NEWCOUNTER STR ( MYCOUNTER , 1 , POS - 1 ) + "0"
  IF POS < 4
     SETVAR NEWCOUNTER NEWCOUNTER + STR ( MYCOUNTER , POS + 1 , 4 - POS )
  ENDIF
  SETVAR MYCOUNTER NEWCOUNTER
  SETVAR POS POS - 1
  INCR36 POS
ELSE
  SETVAR VALIDDIGITS "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ"
  SETVAR CURRPOINTER POS ( CURRVALUE , VALIDDIGITS , 1 )
  SETVAR NEXTVALUE STR ( VALIDDIGITS , CURRPOINTER + 1 , 1 )
  SETVAR NEWCOUNTER STR ( MYCOUNTER , 1 , POS - 1 ) &
                  + NEXTVALUE
  IF  POS < 4
    SETVAR NEWCOUNTER NEWCOUNTER + STR ( MYCOUNTER , POS + 1 , 4 - POS )
  ENDIF
  SETVAR MYCOUNTER NEWCOUNTER
ENDIF


K Tracy Pierce
Systems Programmer
Golden Gate Bridge, Hwy & Trnsp Dist
San Francisco, CA  94129-0601

ATOM RSS1 RSS2