• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Adobe API: combine .docx file with .pdf file

New Here ,
Feb 22, 2023 Feb 22, 2023

Copy link to clipboard

Copied

Hi,

I am using the Adobe API for .net.

I have 2 files (file1.docx & file2.pdf) and I need to merge both output to pdf file(file3.pdf) programmatically.

Using createPDFOperation, I know how to convert file1.docx to file1.pdf file. Later, I can use the combineFilesOperation to combine file1.pdf + file2.pdf = file3.pdf.

However, by following this process, I am creating file1.pdf which I will be discarding any way. Only reason I am creating file1.pdf is to combine both files. Not sure you can combine docx and pdf files in same operation. I tried and it did not work.

I am not sure if this is the right approach and hence, I am reaching out to the community to know if there is any other alternate approach.

Thanks in advance.

Regards,

Chocks

TOPICS
.NET SDK , Document Generation API , PDF Services API

Views

350

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Community Expert , Feb 23, 2023 Feb 23, 2023

At this time you will need to convert the .docx and then combine in two separate operations. The SDKs make this pretty easy though. You can pass the FileRef output of one service to the input FileRef of the next without having to actually save it.

Votes

Translate

Translate
Community Expert ,
Feb 23, 2023 Feb 23, 2023

Copy link to clipboard

Copied

At this time you will need to convert the .docx and then combine in two separate operations. The SDKs make this pretty easy though. You can pass the FileRef output of one service to the input FileRef of the next without having to actually save it.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 27, 2023 Feb 27, 2023

Copy link to clipboard

Copied

LATEST

Hi Joel,


Thanks for the response.
Yes, I passed FileRef to AddInput method in CombineFilesOperation class and it worked.
So now I am not saving the file to disk.

Regards,

Chocks

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources