Answer the question
In order to leave comments, you need to log in
COM object from c#. Accessing a property?
Hello, now I will try to lay out the essence of the problem:
A number of com-libraries are registered and connected to the project.
I get the value like this:
ComObject1 com = new ComObject1();<br/>
string name = com.get_Property("name") as string;
((dynamic)com).name = "Vasiliy";
Attempted to read or write protected memory. This is often an indication that other memory is corrupt
Answer the question
In order to leave comments, you need to log in
I occasionally see this kind of "nonsense" when working with COM, and it's always caused by errors in memory handling in the COM library (for example, premature destruction of an object due to errors in reference counting). I can’t say for sure that this is your case, but it looks very similar.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question