Array problem
Richard Kreiss
rkreiss at gccconsulting.net
Tue May 31 14:13:34 PDT 2016
I have written a –v select process which uses an array to hold the values for the records to be selected. When I test this program with one value at some point the value disappears.
Dim dcode(21)(4,.0)
I have checked the value of dcode[“1”] through the processing by using msgbox ‘Line NN dcode =”<dcode[“1”]
At line 13 the msgbox shows the value in dcode[“1”]; by line 15 dcode[“1”] is empty. Note however temp[“1”} is not empty. The temp array mirrors the dcode array.
After checking the entry with more than one value, the whole array is empty.
Can anyone explain why dcode loses all of its values after executing line 12?
The auto processing table is not running, not this the a clear dcode executed between lines 8 and 35 which execute the record selection.
Richard Kreiss
GCC Consulting
8 ------- - - - - - - - - - - - - - - - -
◄ If:
Then: dim dcode(21)(4,.0):za
9 ------- - - - - - - - - - - - - - - - -
◄ If:
Then: dim temp(21)(4,.0)
10 ------- - - - - - - - - - - - - - - - -
op ◄ If: dcode["1"]= ""
Then: GOTO begin
11 ------- - - - - - - - - - - - - - - - -
◄ If:
Then: msgbox "Line 11 Dcode ="<dcode["1"]
12 ------- - - - - - - - - - - - - - - - -
◄ If: doc_code lt dc
Then: lookup - k=dc i=F –NG
13 ------- - - - - - - - - - - - - - - - -
◄ If:
Then: msgbox "Line 13 Dcode ="<dcode["1"]
14 ------- - - - - - - - - - - - - - - - -
◄ If: doc_code gt LastDoc
Then: lookup - k=(HighNum) i=F -NG
15 ------- - - - - - - - - - - - - - - - -
◄ If: doc_code gt dcode["1"] and dcode["2"] = "" or dcode["2"]="9999"
Then: lookup - k=(HighNum) i=F -NG
16 ------- - - - - - - - - - - - - - - - -
◄ If:
Then: GOSUB chk_doc
17 ------- - - - - - - - - - - - - - - - -
◄ If: ownership = ""
Then: END
18 ------- - - - - - - - - - - - - - - - -
◄ If: pstatus = "" and status_sales = "6"
Then: GOTO sel_own
-------------- next part --------------
A non-text attachment was scrubbed...
Name: winmail.dat
Type: application/ms-tnef
Size: 15566 bytes
Desc: not available
URL: <http://mailman.celestial.com/pipermail/filepro-list/attachments/20160531/fd366b5e/attachment.bin>
More information about the Filepro-list
mailing list