1. È incredibile!

Why not "Array" instead of "Any" - it's one...

2. Without a formal UBOUND, The easiest way for Oxygen to emulate this mode of param passing would be:

function fun(double*d, sys n)
sys i

for i=1 to n
' d[i] ...
next
end function

double d={1,2,3,4,5,.6,.7,.8}
fun d, countof d

3. i'm trying but trying to call a type-function always Errors, unbalanced parentheses, my test won't run
```Uses "Console"

Type t_Test
X   As Long
fun As Function

End Type

Function t_Test.fun(ByVal l(Any) As Long)

End Function

Dim x As t_test

x.fun((1,2,3))

WaitKey
```

4. Sorry Rene but so far it is only for standard functions.
Give me few days and I will extend much more.

5. Sorry again Rene, it was just a matter of ... minutes
Attached a new thinCore.dll

Here a working example:
```Uses "Console"

PrintL "From inside " & Function_Name
PrintL "----------------------------------------------------------------------------"

PrintL "Listing all values:"
For lCount As Long = 1 To UBound(FirstVariadicParam)
PrintL " - Element", lCount, "has value of", FirstVariadicParam(lCount)
Next
PrintL

End Function

Type t_Test
X   As Long
fun As Function
End Type

Function t_Test.fun(ByVal l(Any) As Long)
PrintL "From inside " & Function_Name
PrintL "----------------------------------------------------------------------------"

PrintL "Listing all values:"
For lCount As Long = 1 To UBound(l)
PrintL " - Element", lCount, "has value of", l(lCount)
Next
PrintL

Function = UBound(l)

End Function

Dim x As t_test

x.fun((1,2,3))

Randomize Timer
'---Because first parameter is variadic, pass any number of numeric expressions in surrounding round brackets
PrintL "Function exit value", Variadic1((123, 456, 789, Sin(Rnd), Cos(Rnd)), "ABCDE")

WaitKey
```
I'm going to bed now: today I just did 14 working hours, I'm really tired

6. OK, thanks once more. Sleep well.

Perhaps you can look over the array-scan - theres still some problem with continous scan- returns wrong numbers

and have a look into support-section too please.

Now this my unlimited multidimensional layover-example upon some array at heap (fits the tB-structure up to 3 dimensions if 1-based), needs the units below and the thincore from above.
```Uses "console"
' needs 1.9.14 + latest thincore.dll

#INCLUDE "Heap_Array.tBasicU"

Function TBMain()

Local harry As Heap_Array

Local Bounds(3) As Dimensions

' want 3 dimensional grid of pointers, 1-based

Bounds(1).LoBound = 1 : Bounds(1).HiBound =  2
Bounds(2).LoBound = 1 : Bounds(2).HiBound =  4
Bounds(3).LoBound = 1 : Bounds(3).HiBound =  6

' call to allocate and set up the dimensions at once
harry.PtrsAlloc( harry.BoundsBe( Memory_Get(VarPtr(Bounds(1)), SizeOf(Bounds)) ))

' place a
Local lPtr As DWord At harry.ElementPtr(( 1,2,3 ))

' load the lPtr with data
lPtr = HEAP_AllocByStr("i test 1,2,3")

SetAt( lPtr, harry.ElementPtr(( 2,1,5 )) )
lPtr = HEAP_AllocByStr("i test 2,1,5")

SetAt( lPtr, harry.ElementPtr(( 2,4,6 )) )
lPtr = HEAP_AllocByStr("i test 2,4,6")

' now place standarc-tb-array upon

Local test(2,4,6) Like harry.Layover() At harry.DataPtr

PrintL HEAP_Get(test(1,2,3))
PrintL HEAP_Get(test(2,1,5))
PrintL HEAP_Get(test(2,4,6))

PrintL \$CRLF & "-----------------------key to end"
WaitKey

End Function
```

7. Eros,

The new thinCore.dll you posted, is it to replace the one
that is in the root of the thinAir sub-directory? I one
there is 1,293,824 bytes. Your new one is only 171,008
bytes.

The reason I ask, is that thinBasic did not install a
thinCore.dll in my thinBasic's root directory as you indicate
on Page-1.

Help,

Bill

8. Hi Bill,

inside \thinBasic\ThinAir\ directory there is a special version of thinCore.dll specifically designed to be used only by thinAir.
Do not touch content of that directory.

To test thinCore.dll attached into this post, replace the one you have into \thinBasic\ directory.

Eros

9. Just once more i want to say this is a great feature - really happy that you made this possible Eros.

Still thinking about some similar reverse-operation so a function can pass a variadic result back.

Currently it works alike this
(use is mostly for creating a list of items that meet certain conditions which is just needed once - else i store the list at heap and return the pointer)

```Type t_Item
isVisible As Boolean
End Type

Function ListVisibleItems( Byval ItemID(Any) As Long ) As String

Local i As Long
Local sResult As String

For i = 1 to Ubound(ItemID)
If myItem(ItemID(i)).isVisible Then
sResult += MKL\$(ItemID(i))
Endif
Next
Function = sResult

End Function

Dim myItem(100) As t_Item
'...assume a few items set visible, a few are not

String sVisible = ListVisibleItems((1,2,3,4,5,6,9,14,22,23,24,31,16))

Local lVisible(StrPtrLen(StrPtr(sVisible))/SizeOf(Long)) As Long At StrPtr(sVisible)

' now lVisible() contains all visible items of the list i passed.
```

how would that work?
```Dim lVisible(Any) As Long = ListVisibleItems((1,2,3,4,7,8,43,55))

ReDim lVisible(Any) = ListVisibleItems((5,6,7,8,22,33,43,44,45,57,58))
' ???
Redim lVisible(Any) = "" ' sets Ubound(0) - would be essential - complicated? :(

Dim myPlaylist(Any) As mp3FileInfo = File_Load("c:\myPlaylist.dat")
```
i think it's complicated ...

but perhaps we can live with the current available methods for the meantime and focus on something else then.

10. Eros,

Thank you for the clarification. But, you did not
address the thinCore.dll not installing on my
computer. So;

I renamed my thinBasic directory and re-installed
1.9.14.0. This time it installed. Not only that, but
two other files installed in the thinBasic root
directory: thinBasic.exe and thinBasicc.exe. They
were not in my previous directory(??). How has
my thinBasic been running without them. And,
if it has been running okay, why are they needed?

I hope I am not asking stupid questions. I am 68
and I feel that if I don't ask questions and learn
something everyday, the day is wasted.

Thanks, Again,

Bill

Page 2 of 2 First 12

There are no members to list at the moment.

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•