Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7524843
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T03:10:11+00:00 2026-05-30T03:10:11+00:00

I created a Microsoft Word document and tried to write the buffered image to

  • 0

I created a Microsoft Word document and tried to write the buffered image to it but all I got was garbled text. Is there a way to write (preferably append) a buffered image to a doc or RTF file?

I want to avoid using docx4j or iText or any external package for that matter due to some constraints. But if there is no other way then please do let me know.

My code in case anyone needs for reference:

ps_file = new File("ps_file.doc");
ImageIO.write(i1, "jpg", ps_file);
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T03:10:13+00:00Added an answer on May 30, 2026 at 3:10 am

    Word Documents have their own syntax to store their data so you can’t just append text to them and expect it to just work.

    You will have to use a 3rd party library unless if you’re willing to reinvent the car.

    You can however create an RTF file which stores the image. There’s a question similar to it that’s been answered here:

    Programmatically adding Images to RTF Document

    Obviously it’s for C# but the same procedures can easily be applied in Java.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a report document created by Microsoft Reporting but instead of using its
I'm trying to open a word document and just extract all the text that
I have an object created in memory using Microsoft.Office.Interop and Microsoft.Office.Word and with all
Is there a way to create styles in PowerPoint VSTO to format text, something
I have some C# automation code which does interesting things with Microsoft.Office.Interop.Word.Document objects. The
All, Cannot I have created a Word2007 Document Project and I'm trying to retrieve
I am using Interop.Microsoft.Office.Interop.Word.dll to dynamically build a Word document in C#. Does anyone
I have automated word document creation from templates using the Microsoft Word 12.0 Object
I have created a document template file (.dotx) in Word 2007 and in this
Is there any way I can create doc file using C#. I have tried

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.