01-06-2005, 09:14 PM
Some of the new data type don't mix well and can cause a program to crash, for example in the following code
The program crashes when the call is made to the function addone.
This only occurs with arrays. If mytype was just a normal variable, it does not crash. (ie dim mytype as mytypeT)
Code:
declare function addone(a)
type mytypeT
a as byte
end type
dim mytype(1 to 100) as mytypeT
for i = 1 to 10
m = addone(mytype(i).a)
next i
sleep 1000
function addone(a)
addone = a+1
end function
The program crashes when the call is made to the function addone.
This only occurs with arrays. If mytype was just a normal variable, it does not crash. (ie dim mytype as mytypeT)