ReferencedOLEFileDescriptors.Add

ReferencedOLEFileDescriptors.Add

Anonymous
Not applicable
961 Views
5 Replies
Message 1 of 6

ReferencedOLEFileDescriptors.Add

Anonymous
Not applicable
If I use the function ReferencedOLEFileDescriptors.Add with the option of embedding a file I get an "Invalid Procedure" call error.
It works fine if I link the file.
Any ideas?
0 Likes
962 Views
5 Replies
Replies (5)
Message 2 of 6

Anonymous
Not applicable
This works:

Dim oDrawDoc As DrawingDocument
Set oDrawDoc = ThisApplication.ActiveDocument
Dim xtt As ReferencedOLEFileDescriptor
Set xtt = oDrawDoc.ReferencedOLEFileDescriptors.Add("1.doc")
Unload Me

This does NOT:
Dim oDrawDoc As DrawingDocument
Set oDrawDoc = ThisApplication.ActiveDocument
Dim xtt As ReferencedOLEFileDescriptor
Set xtt = oDrawDoc.ReferencedOLEFileDescriptors.Add("1.doc", kOLEDocumentEmbeddingObject)
Unload Me
0 Likes
Message 3 of 6

Anonymous
Not applicable
The API currently does not support adding embedded OLE references. The only
option is to use linking.

Sanjay-

wrote in message news:5206291@discussion.autodesk.com...
This works:

Dim oDrawDoc As DrawingDocument
Set oDrawDoc = ThisApplication.ActiveDocument
Dim xtt As ReferencedOLEFileDescriptor
Set xtt = oDrawDoc.ReferencedOLEFileDescriptors.Add("1.doc")
Unload Me

This does NOT:
Dim oDrawDoc As DrawingDocument
Set oDrawDoc = ThisApplication.ActiveDocument
Dim xtt As ReferencedOLEFileDescriptor
Set xtt = oDrawDoc.ReferencedOLEFileDescriptors.Add("1.doc",
kOLEDocumentEmbeddingObject)
Unload Me
0 Likes
Message 4 of 6

Anonymous
Not applicable
That would explain why it is not working....

Thanks!
0 Likes
Message 5 of 6

Crstiano
Collaborator
Collaborator

Hi Sanjay,

 

"The API currently does not support adding embedded OLE references "

 

Today (7y ago), this information is valid?

 

 

Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.


Cristiano Oliveira
EESignature
ConsultCAD.com

0 Likes
Message 6 of 6

maxstels
Contributor
Contributor
Also interesting
0 Likes