Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
if ddeinit ExcelLink "excel" c:/meridian/myspreadsheet.xls ; excel file to be used.
if ddeinit SheetLink "excel" "Sheet1" ; Sheet in Excel file to be used.
while 1
(rownr++)
strfmt rowcell "R%dC2" rownr
dderequest SheetLink rowcelle dnbnumber ; Read DNB number from colomb 2.
strreplace dnbnumber "`r`n" ""
strfmt rowcell "R%dC3" rownr
dderequest SheetLink rowcelle tnpos ; read TN-pos from colomb 3.
strreplace tnpos "`r`n" ""
if nullstr tnpos ; If cell is empty were at the end, exiting.
exitwhile
termwrites dnbnumber
termwrites tnpos
endwhile
ddeterminate SheetLink
ddeterminate ExcelLink
else
errormsg "Couldnt open file!"
endif
else
errormsg "No running Excel found!"
endif
Proc main
string dn
integer count
string szline
fopen 0 "dn.wud" read
while not feof 0
SZLINE = "2"
fgets 0 szline
strtok dn szline "t" 1
;strtok dn szline "," 1
set txpace 50
transmit "prt^M"
waitfor "TYPE: "
transmit "dnb^M"
waitfor "CUST "
transmit "0^M"
waitfor "DN "
transmit dn
mspause 10
transmit "^M"
waitfor "DATE "
transmit "^M"
waitfor "PAGE "
transmit "^M"
; waitfor "DES "
transmit "^M"
mspause 6
;pause 1
transmit "^M"
waitfor "NACT "
transmit "^M"
waitfor "REQ: " forever
count += 2
endwhile
fclose 0
fclose 1
call main
endproc
Proc main
string tnb
;string dn
integer count
string szline
fopen 0 "tnb.wud" read
while not feof 0
SZLINE = "2"
fgets 0 szline
strtok tnb szline "t" 1
;strtok dn szline "," 1
set txpace 20
;capture on
;transmit "disu "
;transmit tnb
;transmit "^M"
;waitfor "REQ: "
transmit "prt^M"
waitfor "TYPE: "
transmit "tnb^M"
waitfor "TN "
transmit tnb
mspause 10
transmit "^M"
waitfor "DATE "
transmit "^M"
waitfor "PAGE "
transmit "^M"
waitfor "DES "
transmit "^M"
waitfor "NACT "
transmit "^M"
waitfor "REQ: "
; capture off
;waitfor "REQ: "
count += 2
endwhile
fclose 0
fclose 1
call main
endproc