Load PDF file into NAV 2009R2 and parse into text file

vittoriod
Member Posts: 5
Hi everybody, I would like to know if it is possible to load a pdf file (it contains a data set) into nav and parse it as if it was a text file?
Obviously, what I need to do here is load the pdf file and transform it into a text file or anything similar so I can create my data set from it.
Has anybody ever faced such similar task on NAVISION 2009 R2?
Thanks for your help
Obviously, what I need to do here is load the pdf file and transform it into a text file or anything similar so I can create my data set from it.
Has anybody ever faced such similar task on NAVISION 2009 R2?
Thanks for your help
Vittorio Delmedico
0
Comments
-
0
-
Thanks for the feedback, so there is no way to do that using any existing NAVISION automations or any native NAV functionalities?
ThanksVittorio Delmedico0 -
No, at least to my knowledge.
Other solution is Ghostscript, the last version (9.25)
This is an example of how to use in PowerShell, from an input.pdf you get an output.txt.$tool = 'C:\\Program Files\\gs\\gs9.25\\bin\\gswin64c.exe' & $tool -q -dNOPAUSE -dCOMPLEX -dWRITESYSTEMDICT -dTextFormat=3 -sDEVICE=txtwrite -o c:\test\output.txt c:\test\input.pdf
0 -
Thanks, but this would mean that we would have to install ghostscript on all nav clients in order to execute the '.exe' file? Another question, how would you execute the code you have just attached on NAV 2009 R2 classic client? Thanks a lotVittorio Delmedico0
-
You can use something like this
IF ISCLEAR(WSHShell) THEN CREATE(WSHShell); WSHExec := WSHShell.Exec(program);
Where WSHExec is:Name DataType Subtype Length WSHExec Automation 'Windows Script Host Object Model'.WshExec
And program is:program := 'C:\Program Files\gs\gs9.25\bin\gswin64c.exe -q -dNOPAUSE -dCOMPLEX -dWRITESYSTEMDICT -dTextFormat=3 -sDEVICE=txtwrite -o c:\test\output.txt c:\test\input.pdf'
0 -
Thank you very much so I should treat it as a normal script.. I'll try and let yo know the resultVittorio Delmedico0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions