How to embed, not link files to writer?

I need to embed a file into a Writer document. I need to do this, so that I can share the information with a customer, and they will not be able to see my hard drive, so any link would be broken, but I want them to be able to see the supporting documents for the paper that I am writing.

I have tried inserting a OLE document, and when I do that with a PDF it gives me a “general error / input output error”. I have tried all of the links stuff, either with test or button, and that is what is says, a link back to the location of the file on my hard drive.

In word, there is an embed feature that allows the file to be embedded, not linked, and that allows for someone else to see the supporting documents without them being in their face all of the time. They only need to see the information if they click on the embedded file to actually see it.


@Srysdam: please don’t create questions as Community Wiki. There’s guidelines for asking that you may find useful.

MS Office uses OLE to embed files into documents. This technology allows an application to embed some byte stream into its document, which this application cannot open itself, but the byte stream includes information about which other application was used to create the stream, and thus able to open that stream. So first application (office suite) looks for that other application on system, finds and launches it, and passes it the embedded byte stream. Then the second application does what it needs to do (it may be editing the byte stream contents, or saving it as another file, or anything else).

The data in byte streams may serve two main purposes:

  1. Be a part of composite document, like an image, or a table embedded into a text document. Unlike the tables or images inserted by the text editor native means, the OLE-embedded parts like that need external applications to be edited, but may show even without those applications (using cached images).
  2. Be “attachments” to the document, i.e., don’t show their contents in parent document, but be shown just like icons. To see their contents, one definitely needs relevant application.

LibreOffice also supports the OLE technology, and you may use it in your documents.

Embedding an arbitrary file into a document on Windows is possible using a special OLE server (application) named simply “Package”. It is present on all Windows platforms, and is able to store files inside its byte stream. You may create an OLE object using it, and when asked, select required document.

But you need to understand the implications. The technology required the application that is able to parse the binary stream created by original application that created the OLE object (it is not the office suite, but the app launched by the suite). The byte stream is not identical to the original file. It means that if the system does not have such application installed, then you may be unable to open the attachment on a target system, or on your future system after an upgrade, when you will discover that the app required is no longer developed and supported for your current OS. Even if the object is just an image (like JPG), you may have no way to extract it later, if you haven’t inserted it using usual means, but embedded it as, say, Photoshop OLE object. The Package OLE server is absent on Linux, as seen in tdf#104065.

My strong suggestion is to use separate files and send them as is, along the main file.