Re: PowerBuilder and GetAttributes not firing attr - WeOnlyDo Discussion board

Re: PowerBuilder and GetAttributes not firing attr (General questions)

by woddrazen, Friday, September 18, 2009, 18:10 (5333 days ago) @ fundementals

Charles,


We tried debugging this, but couldn't figure this out. The Event is riggered, and all the code processed, but PB doesn't raise notification for it.

However, why don't you try using DirItems collection instead? DirItems collection is populated when ListDir is executed, and contains the same arguments, such as Size, permissions etc...

Here is example in VB
[code]...
dlx1.Blocking = True
dlx1.Connect

dlx1.ListDir /home/somefolder

Dim i As Integer

For i = 0 To dlx1.DirItems.Count - 1
If dlx1.DirItems(i).Name = filename.txt Then
Debug.Print dlx1.DirItems(i).Name & - Size: & dlx1.DirItems(i).Size
End If
Next i[/code]
Drazen


Complete thread: