PDF-Tools (v7): is there a way to log all processed files in a log file?  SOLVED

This Forum is for the use of End Users requiring help and assistance for Tracker Software's PDF-Tools.

Moderators: TrackerSupp-Daniel, Tracker Support, Vasyl-Tracker Dev Team, Chris - Tracker Supp, Sean - Tracker, Tracker Supp-Stefan

Post Reply
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Hi,
When doing a script, is it possible to add an action to log all processed filenames/path in a log
file along results (success / skipped) for each?
Regards
Bernie
User avatar
Sean - Tracker
Site Admin
Posts: 175
Joined: Wed Sep 14, 2016 5:42 pm
Location: British Columbia

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by Sean - Tracker »

Hi Bernard,

Can you please clarify what you mean by "When doing a script"?

Presently, there is no action in PDF-Tools that can be used to log processed filenames/paths etc in the Actions Library of the software. However, there is a Tool Report feature that can be used to create and save a breakdown of which tools are used, which files are processed, the outcome of each tool operation - success/failure etc. Click the Options menu, then click Tool Report to enable/disable the feature. It will appear in the lower section of the user interface, as detailed in the image below. Click Options to determine which messages are displayed, and/or click Save to save tool reports to a text file.
tool.report.image.png
Hope this helps,

Sean,

Tracker Software Products
Sean Godley
Technical Writer
Tracker Software Products (Canada) LTD
Sales: +1 (250) 324-1621
Fax: +1 (250) 324-1623
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Hi,

Thanks for the suggestion. I will have a look at. May be this could answer what I'm looking for.

Initially my intend is to have a trace of files processed by a particular script since the creation of the
script.

Regards
Bernard
User avatar
TrackerSupp-Daniel
Site Admin
Posts: 8436
Joined: Wed Jan 03, 2018 6:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by TrackerSupp-Daniel »

Hello Bernard,
Just to verify, when you say Script, you do mean the actions on a tool correct?
My interpretation is thus, so please excuse me if my answer here is not helpful.

The Tool Report function has a great degree of customization available, and can be setup to show all messages, as well as the ability to save the report afterwards. This may help in your endeavors!
Attachments
DMKB18July245.png
Dan McIntyre - Support Technician
Tracker Software Products (Canada) LTD

+++++++++++++++++++++++++++++++++++
Our Web site domain and email address has changed as of 26/10/2023.
https://www.pdf-xchange.com
Support@pdf-xchange.com
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

hi,
in answer to: you do mean the actions on a tool correct?
Yes
Regards
Bernard
User avatar
TrackerSupp-Daniel
Site Admin
Posts: 8436
Joined: Wed Jan 03, 2018 6:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by TrackerSupp-Daniel »

:)
Dan McIntyre - Support Technician
Tracker Software Products (Canada) LTD

+++++++++++++++++++++++++++++++++++
Our Web site domain and email address has changed as of 26/10/2023.
https://www.pdf-xchange.com
Support@pdf-xchange.com
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Hi,
I did test... looks like report is not updated when script (tools) il lauch by drag&drop files onto a tool shortcut on the desktop.
Is that the same at your side?
Regards
Bernard
User avatar
TrackerSupp-Daniel
Site Admin
Posts: 8436
Joined: Wed Jan 03, 2018 6:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by TrackerSupp-Daniel »

Hello Bernard,
So long as all the required options are set in the reporting pane, I find that the tools report fills up regardless of the tool start method.
Please ensure you are using V7 build 326, you should be seeing messages populate the log if it has been configured correctly.
Dan McIntyre - Support Technician
Tracker Software Products (Canada) LTD

+++++++++++++++++++++++++++++++++++
Our Web site domain and email address has changed as of 26/10/2023.
https://www.pdf-xchange.com
Support@pdf-xchange.com
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Hi,
My actual installed version is
version
version
capture_version.PNG (12.12 KiB) Viewed 11562 times

and settings are
settings
settings

and log is not updated when using drag&drop
Do you thing 326 will solve this?
Regards
Bernard
User avatar
TrackerSupp-Daniel
Site Admin
Posts: 8436
Joined: Wed Jan 03, 2018 6:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by TrackerSupp-Daniel »

Hello Bernard,
It seems that you will need to have Messages d'information enabled in order to see these messages.
Dan McIntyre - Support Technician
Tracker Software Products (Canada) LTD

+++++++++++++++++++++++++++++++++++
Our Web site domain and email address has changed as of 26/10/2023.
https://www.pdf-xchange.com
Support@pdf-xchange.com
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Hi,
Thanks,
I have installed last version to test w/o success.
Report log is only updated when I execute a script from within PDFtools.
Usually PDFTools is not started at my site. I use to drag&drop files onto desktop
shortcuts and whatever I do, I don't see anything in the report pane with
is always empty when I start PDFtools to review log.
May be something else should be done at my side?
Regards
Bernard
User avatar
TrackerSupp-Daniel
Site Admin
Posts: 8436
Joined: Wed Jan 03, 2018 6:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by TrackerSupp-Daniel »

Hello Bernard,

I have reported this to the Dev team and may be creating a formal bug report shortly.
Terribly sorry for the inconvenience this has caused.
Dan McIntyre - Support Technician
Tracker Software Products (Canada) LTD

+++++++++++++++++++++++++++++++++++
Our Web site domain and email address has changed as of 26/10/2023.
https://www.pdf-xchange.com
Support@pdf-xchange.com
User avatar
TrackerSupp-Daniel
Site Admin
Posts: 8436
Joined: Wed Jan 03, 2018 6:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by TrackerSupp-Daniel »

Hello again Bernard,
After speaking with the dev team, i have found the cause of the issue.

I had misinterpreted you before, and had falsely assumed you were dragging the files onto the tools within the PDf-Tools window.
Knowing now that you were using a shortcut within windows i have some more news. The windows shortcuts use command line switches for their reporting independently from the GUI. however they are uable to log every action that occurs, and can only report errors.

To enable error reporting for the shortcuts/command line please include the following to your tool:

Code: Select all

/RunTool:showrep=always
The /RunTool portion should already exist, simply append the :showrep=always afterwards.
Meaning that your target shortcut properties should appear akin to this:

Code: Select all

"C:\Program Files\Tracker Software\PDF Tools\PDFXTools.exe" /RunTool:showrep=always "{E40C0181-8406-40FA-9BECBB2C3522472B}"
DMKB18July308.png
Dan McIntyre - Support Technician
Tracker Software Products (Canada) LTD

+++++++++++++++++++++++++++++++++++
Our Web site domain and email address has changed as of 26/10/2023.
https://www.pdf-xchange.com
Support@pdf-xchange.com
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Hi,
I did test and it works but not as expected!
I got the report on screen after completion of tool execution...I expected something silent/hidden with cumulative log in a log file which could be reviewed later.
Is there something possible to output result added (appended) to a log file?
Regards
Bernard
User avatar
DenisO
Site Admin
Posts: 104
Joined: Fri Jun 09, 2017 5:40 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by DenisO »

bernard meunier wrote:Hi,
I did test and it works but not as expected!
I got the report on screen after completion of tool execution...I expected something silent/hidden with cumulative log in a log file which could be reviewed later.
Is there something possible to output result added (appended) to a log file?
Regards
Bernard
Hi Bernard,
try to use /Log:full option. For example: PDFXTools.exe /Log:full D:\tools.log /RunTool "pdft.tool.resizePages". Hopefully this will help.
Best regards
Denis Oleksenko
Software Developer
Tracker Software Products (Canada) LTD
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Great! more or less this do the job...I tested Something like >>D:\Tools.log so that to have cumulatives entries
but this Don't works :-(
Is there Something I can do?
Bernard
User avatar
DenisO
Site Admin
Posts: 104
Joined: Fri Jun 09, 2017 5:40 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by DenisO »

bernard meunier wrote:I tested Something like >>D:\Tools.log so that to have cumulatives entries
What is you scenario of executing tool? Do you want to append report to the log file after every tool execution? Currently PDF Tools do not append log files.
Note that PDF Tools have feature to monitor specific folder and execute tool on new files added to the folder ( Options->Folder Monitors). There you can save report using special macros, for example timestamp
report.JPG
Denis Oleksenko
Software Developer
Tracker Software Products (Canada) LTD
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Hi,

Thanks, I think I have too have a look to folder monitoring but my usage of desktop tools
won't probably not be compatible / appliable:

I used to organize pdf files (natively created or scanned document) within folders and sub-folder
organized by topic: payrol / bank / insurance /health. For convenience not all files are password
protected within a folder. I'm only protecting some of them using a drag&drop onto relevant tool
desktop shortcut. Using folder monitor feature would oblige to have 2 folders within each topic
folder: one monitored (for docs needing password) and the other not. This will oblige user (me!)
to add any new folders to the monitored list...not enough convenient for me.

To answer the question "Do you want to append report to the log file after every tool execution?"
Yes:
I'm looking for cumulative log ... and if desired for convenience not be displayed to
user after tool execution for exemple only in case of tool execution error or.

The ultimate goal is to be able to parse the log file to see either or not a particular file
have ever been processed. This is the case when I don't found a file in a folder where
it is expected to be... cummulative log would help determining either or not a "such" named
file could have ever been processed (have existed!).

Hope this help clarifying.
Regards
Bernard
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17810
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by Tracker Supp-Stefan »

Hello Bernard,

So you need not just a log, but a record of all files processed. I am afraid that logs are normally not intended to work that way.
You can either try with the timestamps as DenisO suggested, or make sure after every use of the PDF Tools to check the generated Log and copy the list of processed files in a separate file that you will keep as a "list of processed files" record.

Regards,
Stefan
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Hi Stefan,

More or less you well understood what I was looking for.
I understand that I won't get this off the shelf... may be you will add later on a switch
so that to be able to have all reports cumulated in a file? (wish!)

Thanks
Regards
Bernard
User avatar
DenisO
Site Admin
Posts: 104
Joined: Fri Jun 09, 2017 5:40 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by DenisO »

Hi Bernard,
I have temporary solution for you. In attachemt you can find archive with VBsript which runs tool and then appends its report to full log. You can drag and drop files on it.
In order to run your tool you should change:
toolName - Your tool name
toolLog - path to log to save report from last run
fullLog - path to log with previous reports to append new one
On my side everything works fine. I hope this will help you.
Attachments
RUNcopy.zip
(588 Bytes) Downloaded 148 times
Denis Oleksenko
Software Developer
Tracker Software Products (Canada) LTD
User avatar
TrackerSupp-Daniel
Site Admin
Posts: 8436
Joined: Wed Jan 03, 2018 6:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by TrackerSupp-Daniel »

Thanks for that DenisO!

Looking forward to hearing if that helps Bernard :)
Dan McIntyre - Support Technician
Tracker Software Products (Canada) LTD

+++++++++++++++++++++++++++++++++++
Our Web site domain and email address has changed as of 26/10/2023.
https://www.pdf-xchange.com
Support@pdf-xchange.com
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Hi,
I will have a look next weekend. thanks.
I will came back later on with results.
Regards
Bernard
User avatar
TrackerSupp-Daniel
Site Admin
Posts: 8436
Joined: Wed Jan 03, 2018 6:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by TrackerSupp-Daniel »

:)
Dan McIntyre - Support Technician
Tracker Software Products (Canada) LTD

+++++++++++++++++++++++++++++++++++
Our Web site domain and email address has changed as of 26/10/2023.
https://www.pdf-xchange.com
Support@pdf-xchange.com
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Hi,
I did test and I'm facing an issue because names includes spaces!
I did try adding """ in the script but I Don't manage getting the script properly working…
the script is well started but Don't get filnames and log in empty.

here is an example ; "C:\Apl\Tracker Software\RUNcopy.vbs" "D:\DHome\XPdocs\Papa\paperport_pdf\CL&Banque\Banque Postale\Compte Indivis\Relevés de comptes\Copie de BPI relevé n°7 juillet2018 20180804.pdf"
I Added a msgbox in the script and got Following:
[img]
CaptureResult.PNG
CaptureResult.PNG (6.25 KiB) Viewed 11418 times
[/img]

I did test for docs w/o spaces in name of dir path an it worked fine… at least for one file.
Directions or tips are welcome.

at this time script look like :
toolLog = "D:\DHome\XPdocs\Papa\GestPC\Rapport_PDFTools.txt"
fullLog = "D:\DHome\XPdocs\Papa\GestPC\Rapport_PDFTools_cumul.log"
toolName = "{E4919750-1F40-4BDE-95B53757E3145820}"
toolsPath = """C:\\Apl\\Tracker Software\\PDF Tools\\PDFXTools.exe"""
list = ""

Set objArg = WScript.Arguments
if objArg.count = 0 then WScript.Quit
for i=0 to objArg.Count-1
list = list & objArg(i)& " "
next

command = toolsPath & " /Log:full """ & toolLog &" "" /RunTool """ & toolName & """ " & list
msgbox command


Set WshShell = CreateObject("WScript.Shell")
retcode = WshShell.Run(command, 1, true)
if retcode = 0 then

Set fs = CreateObject("Scripting.FileSystemObject")
Set fLog = fs.OpenTextFile("" & fullLog &"",8,true, -1)
Set tLog = fs.OpenTextFile("" & toolLog &"", 1, false,-1)

data_file = tLog.ReadAll

fLog.Write(data_file)
fLog.Close()
tLog.Close()
else
msgbox retcode

End if
Regards
Bernard
User avatar
DenisO
Site Admin
Posts: 104
Joined: Fri Jun 09, 2017 5:40 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?  SOLVED

Post by DenisO »

Hi Bernard,
I've fixed the script to work with spaces in filenames. Please see the attachment
Attachments
runtool.zip
(592 Bytes) Downloaded 150 times
Denis Oleksenko
Software Developer
Tracker Software Products (Canada) LTD
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Hi,

Thanks, I will test it next weekend. Be sure I will give you feedback after testing.

Regards
Bernard
User avatar
Tracker Supp-Stefan
Site Admin
Posts: 17810
Joined: Mon Jan 12, 2009 8:07 am
Location: London
Contact:

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by Tracker Supp-Stefan »

Thanks for this scriot DenisO!

Looking forward to your feedback Bernard!

Regards,
Stefan
bernard meunier
User
Posts: 120
Joined: Tue May 06, 2014 7:52 pm

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by bernard meunier »

Perfect !

I had a chance to test it and new script well works as expected.
Special thanks to DenisO.

Regards
Bernard
User avatar
Paul - Tracker Supp
Site Admin
Posts: 6829
Joined: Wed Mar 25, 2009 10:37 pm
Location: Chemainus, Canada
Contact:

Re: PDF-Tools (v7): is there a way to log all processed files in a log file?

Post by Paul - Tracker Supp »

:)
Best regards

Paul O'Rorke
Tracker Support North America
http://www.tracker-software.com
Post Reply