strPath = CreateObject ("Scripting.FileSystemObject").GetAbsolutePathName(".") & "\"
Set TK = CreateObject("APToolkit.Object")
numPgs = TK.Numpages("output.pdf")
Dim filesys, testfile
Set filesys = CreateObject("Scripting.FileSystemObject")
Set testfile = filesys.CreateTextFile(strPath & "comments.txt", True)
For I = 1 to numPgs
r = TK.ExportComments(I)
testfile.WriteLine "Comments From Page " & I
testfile.WriteLine ""
testfile.WriteLine r
testfile.WriteLine ""
Next
testfile.Close
TK.CloseInputFile
Set TK = Nothing