Active Topics Memberlist Search Help | |
Register Login |
Programming | |
EXP Systems Forum : PDF reDirect : Programming |
Topic: Merging PDFs with VBA | |
<< Prev Page of 2 |
Author | Message |
alaska-guy
Newbie Joined: 20 Jul 11 Posts: 4 |
Posted: 28 Jul 11 at 1:48PM |
Yes - You do need two files in order to merge! - Did the commenting when I had the first problem and forgot to remove - Sorry should have caught that myselfWorks perfectly now - Thanks
|
|
IP Logged | |
Michel_K17
Moderator Group Forum Administrator Joined: 25 Jan 03 Posts: 1673 |
Posted: 29 Jul 11 at 1:32AM |
No worries.
Cheers! |
|
Michel Korwin-Szymanowski
EXP Systems LLC |
|
IP Logged | |
mytfein
Newbie Joined: 14 Feb 12 Posts: 1 |
Posted: 14 Feb 12 at 4:11PM |
Hi Michel,
Would it be possible for you send me the code, as well.
I need to consolidate pdf files using vba....
tx for your consideration, sandra
|
|
IP Logged | |
AnthonyPrince
Newbie Joined: 09 Mar 12 Location: United States Posts: 2 |
Posted: 09 Mar 12 at 9:49AM |
The final window, titled, 'Choose a file size and conversion setting'
allows you to control the size of your merged PDF document. Consider the
purpose of your new document. -Instant Tax Solutions Scam
|
|
IP Logged | |
dan cecil
Newbie Joined: 24 Nov 12 Location: United States Posts: 2 |
Posted: 26 Nov 12 at 5:15AM |
Hello,
new to the forum here.... I am trying to merge all files in a folder (all are pdf)... using vba in access... I keep getting error 401 files cannot be opened... any ideas? thanks Private Sub Command0_Click() 'fso = CreateObject("Scripting.FileSystemObject") Dim x As Integer Dim fs As Object Dim fl As Object Dim fld As Object Set fs = CreateObject("Scripting.FileSystemObject") Dim count As Integer Dim oPDF As New PDF_reDirect_v25002.Batch_RC_AXD dim TempBool As Boolean Dim strFileNameShort As String Dim Files_to_Merge() As String set fld = fs.GetFolder("\\Pomsserver1\pomsserver\dropbox\MSA\Registration_and_Charges") x = 0 For Each fl In fld.Files x = x + 1 Next fl ReDim Files_to_Merge(x - 1) x = 0 For Each fl In fld.Files Files_to_Merge(x) = fl.Name x = x + 1 Next fl With oPDF TempBool = .Utility_Merge_PDF_Files("\\Pomsserver1\pomsserver\dropbox\MSA\Registration_and_Charges\MergeTest.pdf", Files_to_Merge) If Not TempBool Then ' NOTES ON ERROR CODES for oPDF.ErrorLastDLL ' 401 - One of the Input File could not be opened ' 410 - One of the Input File could not be decrypted MsgBox "An Error Occured: " & .LastErrorDescription & vbCrLf & _ "Error Number =" & Str$(.LastErrorNumber) & vbCrLf & _ "DLL Error Number =" & Str$(.ErrorLastDLL), _ vbExclamation Else MsgBox "Merge Successful.", vbInformation End If End With Set oPDF = Nothing End Sub |
|
IP Logged | |
Michel_K17
Moderator Group Forum Administrator Joined: 25 Jan 03 Posts: 1673 |
Posted: 26 Nov 12 at 7:33PM |
Hi,
I am sorry to hear of the problem. I would check the following:
Cheers! |
|
Michel Korwin-Szymanowski
EXP Systems LLC |
|
IP Logged | |
dan cecil
Newbie Joined: 24 Nov 12 Location: United States Posts: 2 |
Posted: 26 Nov 12 at 8:39PM |
Michel, thanks so much for your quick reply. I did check those items and everything looked good.. I also tried using a local path instead of a network path incase there was any network security issues present... any other ideas?... does the code look ok?... would you have any samples that might have done a similar thing?... merging all files in a folder?... thanks again
Dan |
|
IP Logged | |
Michel_K17
Moderator Group Forum Administrator Joined: 25 Jan 03 Posts: 1673 |
Posted: 26 Nov 12 at 10:59PM |
Hi Dan,
One more thing I noticed in your code: you add all of the files in the "Registration_and_Charges" folder, but you do not check to make sure that they are PDF files before adding them. Is there any chance that other (non-PDF) files are added? Or maybe a hidden file? Cheers! |
|
Michel Korwin-Szymanowski
EXP Systems LLC |
|
IP Logged | |
<< Prev Page of 2 |
Forum Jump |
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |