Hi,
I want to convert PDF file into Excel file by the VBA coding.....
Please help me it's very urgent for me.
Hope to hear you soon
Thank you
Warm Regards,
Rajdeep Singh
Hi,
I want to convert PDF file into Excel file by the VBA coding.....
Please help me it's very urgent for me.
Hope to hear you soon
Thank you
Warm Regards,
Rajdeep Singh
I suggest doing a quick google search.
You can't. You need to either copy and paste or use an external tool, having said that though most of them are not particularly successful
I already search by the google but that is not working.i use below mention VBA code.
Sub ImportPDFFileData()
'Author: Steve Lipsman
'Purpose: Import PDF File Data Into Excel Worksheet
'Other Requirement(s): 'Acrobat' Checked in VBA Tools-References
'Reference Renames Itself 'Adobe Acrobat 9.0 Object Library' After Reference Is Saved
'Declare Variable(s)
Dim appAA As Acrobat.CAcroApp, docPDF As Acrobat.CAcroPDDoc
Dim strFileName As String, intNOP As Integer, arrI As Variant
Dim intC As Integer, intR As Integer, intBeg As Integer, intEnd As Integer
'Initialize Variables
Set appAA = CreateObject("AcroExch.App"): Set docPDF = CreateObject("AcroExch.PDDoc")
'Set PDF FileName
strFileName = "Your Full PDF File Pathname Here.pdf"
'Read PDF File
docPDF.Open (strFileName)
'Extract Number of Pages From PDF File
intNOP = docPDF.GetNumPages
'Select First Data Cell
Range("A1").Select
'Open PDF File
ActiveWorkbook.FollowHyperlink strFileName, , True
'Loop Through All PDF File Pages
For intC = 1 To intNOP
'Go To Page Number
SendKeys ("+^n" & intC & "{ENTER}")
'Select All Data In The PDF File's Active Page
SendKeys ("^a"), True
'Right-Click Mouse
SendKeys ("+{F10}"), True
'Copy Data As Table
SendKeys ("c"), True
'Minimize Adobe Window
SendKeys ("%n"), True
'Paste Data In This Workbook's Worksheet
ActiveSheet.Paste
'Select Next Paste Cell
Range("A" & Range("A1").SpecialCells(xlLastCell).Row + 2).Select
'Maximize Adobe Window
SendKeys ("%x")
Next intC
'Close Adobe File and Window
SendKeys ("^w"), True
'Empty Object Variables
Set appAA = Nothing: Set docPDF = Nothing
'Select First Cell
Range("A1").Select
End Sub
Please use code tags.
That code requires Adobe Acrobat (not just the reader) installed - is it installed on your machine?
i am just installing the same...
The same what?
Adobe Acrobat
Please find the attachment herewith.after install Adobe Acorbat. i am facing this error.
Error.jpg
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks