I'm also seeing another bug. debugProjectFilesCount counts the files in a project, but projectFiles(i) returns "nodes" in the project's tree view (i.e. includes folders).
so, for i = 0 to projectFilesCount-1 msgbox projectFiles(i) next will popup the project name (e.g. "New project") first rather than the first file since the project name is the first node in the tree view, then the first folder name (e.g. "Folder") instead of file 2. You can replicate this by copying this code and saving it as AB_PSPad_Debug1.vbs [color=#0000FF]Const[/color] module_name = [color=#880000]"AB_PSPad_Debug1"[/color] [color=#0000FF]Sub[/color] Init addMenuItem [color=#880000]"Debug"[/color], [color=#880000]""[/color], [color=#880000]"debugProjectFilesCount"[/color] [color=#0000FF]End Sub[/color] [color=#0000FF]Sub[/color] debugProjectFilesCount() [color=#0000FF]Dim[/color] i [color=#0000FF]for[/color] i = 0 [color=#0000FF]to[/color] projectFilesCount-1 [color=#880088]msgbox[/color] projectFiles(i) [color=#0000FF]next[/color] [color=#0000FF]End Sub[/color] just add a couple of files into the default project and click Scripts>debug and you'll see the problem. -- <http://forum.pspad.com/read.php?6,45011,45031> PSPad freeware editor http://www.pspad.com
