G
George
Hi,
I'm having two problems with linking/embedding OLE objects.
The first problem. When I use "Insert|Object...|Create from File" and browse
to a file (say WAV file) then select the file and check "Link to file" I get
an embedded object instead of a linked one; I can't see the object under
"Edit|Links..." and I get the same result whether I check/uncheck the "Link
to File". Also when I iterate through the InlineShapes I see the object is
of Type "wdInlineShapeEmbeddedOLEObject" where it should be
"wdInlineShapeLinkedOLEObject". I loose the link to the original file this
way and can't get a reference to it. The only files I get them linked are
the graphics files and office documents. Any idea why does this happen and
how to link the files instead of embedding them?
The second problem. I want to save each of these embedded objects to a
separate file. If they were linked, then there is no problem since I can get
a reference to the original file. But when they are embedded and I iterate
through the InlineShapes collection I get only an "OLEFormat.ClassType" =
"Package". I tried OLEFormat.object but I get a "No such interface
supported" error, and couldn't find any other property to tell me anything
about the original object. How can I know the exact type of the embedded
file and how can I save the object to an external file?
Thanks,
George
I'm having two problems with linking/embedding OLE objects.
The first problem. When I use "Insert|Object...|Create from File" and browse
to a file (say WAV file) then select the file and check "Link to file" I get
an embedded object instead of a linked one; I can't see the object under
"Edit|Links..." and I get the same result whether I check/uncheck the "Link
to File". Also when I iterate through the InlineShapes I see the object is
of Type "wdInlineShapeEmbeddedOLEObject" where it should be
"wdInlineShapeLinkedOLEObject". I loose the link to the original file this
way and can't get a reference to it. The only files I get them linked are
the graphics files and office documents. Any idea why does this happen and
how to link the files instead of embedding them?
The second problem. I want to save each of these embedded objects to a
separate file. If they were linked, then there is no problem since I can get
a reference to the original file. But when they are embedded and I iterate
through the InlineShapes collection I get only an "OLEFormat.ClassType" =
"Package". I tried OLEFormat.object but I get a "No such interface
supported" error, and couldn't find any other property to tell me anything
about the original object. How can I know the exact type of the embedded
file and how can I save the object to an external file?
Thanks,
George