.script
;===============================================================
.input po4300, 13, 52
.placement 6, 14
.title ' Set PO Receivings (1-step) ', highlight
.line Line1, 52, pos(2,1), horizontal
.line Line2, 52, pos(7,1), horizontal
.paint _
 
.field scan, a10, pos(1,1), prompt("Scan data"), fpos(1,20), -
 help(POSCANDATA), change_method("ANYFLD_CHANGE")
 
.field podate, d8, pos(1,36), prompt("Date"), fpos(1,41), -
 help(PORECDATE), date(today)
 
.field phvend, d8, pos(3,1), prompt("Vendor"), fpos(3,8), format('XXXXXXXX')
.field phname, a30, fpos(3,17)
.field phadr1, a30, fpos(4,17)
.field phadr2, a30, fpos(5,17)
.field phcity, a20, fpos(6,17)
.field phstat, a2, fpos(6,38)
.field phzipc, a10, fpos(6,41)
 
.field item, a24, pos(8,1), prompt("Item ID"), fpos(8,20)
 
.field desc, a30, pos(9,1), prompt("Description"), fpos(9,20)
 
.field rcvd, d9.3, pos(10,1), prompt("Qty remaining"), fpos(10,20), -
 help(POQTYRCVD), copy, format("ZZZ,ZZZ.XXX-")
 
.field acpt, d9.3, pos(11,1), prompt("Qty accepted"), fpos(11,20), -
 help(POQTYACPT), copy, format("ZZZ,ZZZ.XXX-")
 
.field rjct, d9.3, pos(12,1), prompt("Qty rejected"), fpos(12,20), -
 help(POQTYRJCT), copy, format("ZZZ,ZZZ.XXX-")
 
.field abin, a8, pos(13,1), prompt("Bin"), fpos(13,20), -
 help(PORECABIN)

.structure rec1, scan,abin,rcvd,acpt,rjct
.structure rec2, podate
.structure rec8, phvend,phname,phadr1,phadr2,phcity,phstat,phzipc
.structure rec9, item,desc
.set set1, rec1, scan
.set set2, rec1, rcvd
.set set3, rec1, acpt,rjct,abin
.set set8, rec8, phvend,phname,phadr1,phadr2,phcity,phstat,phzipc
.set set9, rec9, item,desc
.set set99, rec2, podate
.end
;
;=============================================================== 
.listclass l_po4300k, items(12), headers(1), footers(1), -
 load_method("posl_po4300k"), options(activex)
.end
;
.input i_po4300k, 1, 100
.display_area 1,1,1,42
.placement 7, 1
.title " Serial/Lot Nos "
.field l_no, d3, pos(1,1)
.field l_deleted, a1, pos(1,4)
.field l_snlt, a20, pos(1,6)
.field l_qty, d6, pos(1,28), format("ZZZ,ZZX")
.structure rec1, l_no,l_snlt,l_qty,l_deleted
.set set1, rec1, l_no,l_deleted,l_snlt,l_qty
.end
;======== Purchase Order entry (kit serial/lot numbers) ========
.input po4300k, 4, 40
.placement 11, 30
.title ' Serial/Lot Number ', highlight
.line Line1, 40, pos(2,1), horizontal
.paint " "

.field positem, a24, pos(1,1), prompt("Kit item"), fpos(1,16)

.field possnlot, a20, pos(3,1), prompt("Serial/Lot no"), fpos(3,16), -
 help(POSERLOTNO), user('#Drill/Req#'), -
 drill_method("INSNLT_FIND"), change_method("ANYFLD_CHANGE")

.field posqty, d9.3, pos(4,1), prompt("Quantity"), fpos(4,16), -
 format("ZZZ,ZZZ.XXX-")

.structure rec1, <39>,possnlot,posqty
.set set1, rec1, possnlot
.set set2, rec1, possnlot,posqty
.end
;
;=============================================================== 
.listclass l_po4300s, items(12), headers(1), footers(1), -
 load_method("posl_po4300"), options(activex)
.end
;
.input i_po4300s, 1, 100
.display_area 1,1,1,42
.placement 7, 1
.title " Serial/Lot Nos "
.field l_no, d3, pos(1,1)
.field l_deleted, a1, pos(1,4)
.field l_snlt, a20, pos(1,6)
.field l_qty, d6, pos(1,28), format("ZZZ,ZZX")
.structure rec1, l_no,l_snlt,l_qty,l_deleted
.set set1, rec1, l_no,l_deleted,l_snlt,l_qty
.end
;============= Purchase Order entry (serial/lot numbers) =======
.input po4300s, 2, 40
.placement 12, 20
.title ' Serial/Lot Number ', highlight
.paint " "

.field possnlot, a20, pos(1,1), prompt("Serial/Lot no"), fpos(1,16), -
 help(POSERLOTNO), user('#Drill/Req#'), -
 drill_method("INSNLT_FIND"), change_method("ANYFLD_CHANGE")

.field posqty, d9.3, pos(2,1), prompt("Quantity"), fpos(2,16), -
 format("ZZZ,ZZZ.XXX-")

.structure rec1, <39>,possnlot,posqty
.set set1, rec1, possnlot
.set set2, rec1, possnlot,posqty
.end
;
;============= Purchase Order entry (serial/lot numbers) ======= 
.input po4300sn, 2, 40
.placement 12, 20
.title ' Serial/Lot Number ', highlight
.paint " "

.field possnlot, a20, pos(1,1), prompt("Serial/Lot no"), fpos(1,16), -
 help(POSERLOTNO), user('#Drill/Req#'), -
 drill_method("INSNLT_FIND"), change_method("ANYFLD_CHANGE")

.structure rec1, <39>,possnlot
.set set1, rec1, possnlot
.set set2, rec1, possnlot
.end
;
;=============================================================== 
