Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Exception Error 0xC0000005. Access violation
#4
Error here:
Code:
Copy      Help
str varSplitPO
;split
tok(varPOBox varSplitPO 2 "x" 2)
You create 1 str variable (varSplitPO), but specify that you need max 2 tokens with tok. Then tok overwrites some other memory.

Correct code:
Code:
Copy      Help
str varSplitPO variableForOtherToken
;split
tok(varPOBox &varSplitPO 2 "x" 2)
out varSplitPO
out variableForOtherToken
or
Code:
Copy      Help
ARRAY(str) varSplitPO
;split
tok(varPOBox varSplitPO 2 "x" 2)
out varSplitPO[0]
if(varSplitPO.len>=2) out varSplitPO[1]


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)