          SUBROUTINE (CMP.COST)
** Version# 1.0002[7] - 04/28/2014 - 11:58am - TSMITH - eclipse
*** V1.0002 Change - Custom Coding . - 04/28/2014 - TSMITH - eclipse
** Copied from BP DICT.CMP.COST.CALC Version# 1 - 03/24/1996 - 08:30pm - SCOTTR - **
          CMP.COST = ''
          OID      = @ID
          INVN     = 1
          MATREAD LED FROM LEDFILE,OID           ELSE RETURN
          *LOCATE INVN IN LED(8)<1> SETTING GEN   ELSE RETURN
          GEN = 1
          LDIDS   = LED(48)<1,GEN>
          LD.CT   = DCOUNT(LDIDS,SVM)
          FOR LDN = 1 TO LD.CT
          LDID    = LDIDS<1,1,LDN>
          IF NUM(LDID) THEN
             LD.GET LDID
             QS  = SUM(LD(5)<1,GEN>) + SUM(LD(6)<1,GEN>)
             CST = LD(27)<1,GEN>
             CMP.COST += ICONV(OCONV(CST,'MR9')*QS,'MR2')
             END
          NEXT LDN

          OE.GET.QSIGN QSIGN,OID,GEN
          CMP.COST = CMP.COST * QSIGN

          RETURN
!TSMITH~04/28/14~11:58
