Loading COM object from clipboard  
Author Message
Mauricio DIAZ ORLICH





PostPosted: Common Language Runtime, Loading COM object from clipboard Top

Hi,

I am trying to write an application that should load equations written in Mathcad via the Clipboard (user copies in Mathcad, pastes in the application).

Mathcad provides an Interop.Mathcad assembly for .NET developers so I have all the interfaces I need, the problem is that the objects in the clipboard can only be recovered as MemoryStreams. I tried using the BinaryFormatter, hoping that maybe it would be able to deserialize the object into the right interface, but it says the object doesn't contain a valid BinaryHeader, which was actually expected since the serialization was not made by the BinaryFormatter in the first place.

Does anyone know if this can be done, and if it can be done, how

Thanks in advance,

Mauricio



.NET Development17  
 
 
nobugz





PostPosted: Common Language Runtime, Loading COM object from clipboard Top

Sounds like a good question to post on the MathCAD user forum...


 
 
Mauricio DIAZ ORLICH





PostPosted: Common Language Runtime, Loading COM object from clipboard Top

Hi,

I'll definitively ask the question in the Mathcad forum, thank you. However, I don't think this is a Mathcad-specific question. Maybe somebody has had the same problem trying to deserialize COM objects set on the clipboard by other applications. If anyone has any ideas, they're all welcome.

Thanks,

Mauricio