C******************** START FILE IXUOPW.FOR ; GROUP URDUTS ******************
C---------------------------------------------
C&  IXUOPW  UREAD INTEGER FCN SET IF INPUT MATCHES PASSED WORD LIST
C
      INTEGER FUNCTION IXUOPW(ZLIST,INUM)
C
      USE USERIO
C
      CHARACTER*(*) ZLIST(INUM)
C
      CHARACTER*40 ZLISTL,ZINPUT
C
C  FIND FIRST FIELD IN BUFFER
C
      ZINPUT=' '
      CALL URWORD(CBUFF,1,IC,ID)
      IF(IC.GT.0) CALL URWRDL(CBUFF(1:IC),ZINPUT,ILINP)
      call uspcap(zinput)
      ILINP=len_trim(zinput)
C
C  CHECK LIST
C
      DO 10 I=1,INUM
        ZLISTL=' '
        ILN=LEN(ZLIST(I))
        ZLISTL(1:ILN)=ZLIST(I)(1:ILN)
        CALL USPCAP(ZLISTL)
        IL=ILNURD(ZLISTL)  ! LENGTH, NOT. INCL. TRAILING BLANKS
        IF(IL.NE.ILINP) GO TO 10
C  LENGTH OF ITH ELEMENT IS CORRECT
        IF(ILINP.EQ.0) GO TO 20
        IF(ZINPUT(1:ILINP).EQ.ZLISTL(1:ILINP)) GO TO 20
C  END OF LOOP
 10   CONTINUE
C  NO MATCH IF FALL THRU
      IXUOPW=0
      RETURN
C
C  MATCH
C
 20   CONTINUE
      IXUOPW=I
C  ROTATE OUT OF BUFFER
      CALL UROTOR(ID)
C
      RETURN
      END
C******************** END FILE IXUOPW.FOR ; GROUP URDUTS ******************
