PDA

View Full Version : I am getting to know thinbasic and ran into something i cant figure out.



F_Dixon
10-04-2024, 08:00
I am making a small program to scan for some files on my pc.
I got side tracked wondering how fast the loops worked.

I found the data structures hash sample and I am substituting arrays for the hash.

I wanted to use this function below

'nRec = ARRAY EXTRACT MainArray, [COLLATE UCASE,] {StartsWith | EndsWith | Contains} 'KEY" & lCount

managed to not post any dumb questions so far, i just dont see my error here.

any pointer welcome.
Fred.

EDITED

I found my mistake. Some sleep and some food and I had an extra comma between CONTAINS , "STRING" where none should have been.

F_Dixon
11-04-2024, 05:05
I am making a small program to scan for some files on my pc.
I got side tracked wondering how fast the loops worked.

I found the data structures hash sample and I am substituting arrays for the hash.

I wanted to use this function below

'nRec = ARRAY EXTRACT MainArray, [COLLATE UCASE,] {StartsWith | EndsWith | Contains} 'KEY" & lCount

managed to not post any dumb questions so far, i just dont see my error here.

any pointer welcome.
Fred.

EDITED

I found my mistake. Some sleep and some food and I had an extra comma between CONTAINS , "STRING" where none should have been.


I really need to watch for spellcheck. I cant either read or spell for crap.

ErosOlmi
12-04-2024, 18:19
Ciao Fred and welcome to thinBasic.

If you have something not working for any reason please post a little example showing the problem you have.
It would be a lot more easier for anyone willing to hep.

thinBasic ARRAY ... syntax I admit it is not the easiest in the world.
It was implemented in that way in order to be compatible with another programming language we love.
Will see if I can create a variant syntax for it.

Ciao
Eros