Hi,
Did you ever manage to resolve this?, I'm having the same problem.
Update: example code of what I got to work.
---------------------------------------------------
Dim folderInfo As DotNetNuke.Services.FileSystem.FolderInfo
Dim fileInfo As DotNetNuke.Services.FileSystem.FileInfo
Dim aryList2 As ArrayList
Dim objFolderController As New DotNetNuke.Services.FileSystem.FolderController
folderInfo = objFolderController.GetFolder(PortalId, imgFolderPath, True)
If Not folderInfo Is Nothing Then
aryList2 = FileSystemUtils.GetFilesByFolder(PortalSettings.PortalId, folderInfo.FolderID)
For Each fileInfo In aryList2
'do you r stuff here
Next
End If
folderInfo = Nothing
fileInfo = Nothing
aryList2 = Nothing
'GC.Collect() - Doing this if you use FileSystemUtils.GetFolder also seems to work, but a bit to drastic!
---------------------------------------------------------------------------------
If anyone has any better ideas please post them.