Folderitem item alternative

I need to walk trough Mac directories and get some file info, I have noticed that the main problem is in the item property as this slows down the process; I only use it once in the loop (converting to a folderitem variable and reuse as suggested) and walk forward but anyway it’s too slow for me.

Is there any alternative to get all files from a folder into an array? Just the nativepath would be fine because opening the files is fast, the bottleneck is in the item.

I have the same process in Visual Studio for Pc and it’s way faster. Is there any plugin for Mac available that is faster than folderitem item?

Thanks in advance.

If you have MBS plugins, if might be quicker to use FolderItem.ItemsMBS (returns an array of Folderitem()). From the docs: Similar to item() function, but returns all items with one call.

Which platform? And can you show us your code?

Showing the code would be the most useful thing to do. The FolderItem iteration code on the Mac framework is about as optimized as it can be given the API constraints, but it all depends on your usage of it.