c++ - Using COM object in parallel_for loop, -


In my code I am using a parallel_for loop, in this loop I am calling from the COM object, But when it moves, it has not been executed correctly, something that says that COM can not be executed in any other thread,

what do I have to do, do I have to multiply or multiply What to do,

This is my code

  COMObject myCom; Parallel_for (tall (1), count, [& amp;] (long i) {myCom-> few calls (i);});  

I think you should set MTAThreadAttribute [MTAThread] need to . For more information see:



Comments

Popular posts from this blog

Python SQLAlchemy:AttributeError: Neither 'Column' object nor 'Comparator' object has an attribute 'schema' -

java - How not to audit a join table and related entities using Hibernate Envers? -

mongodb - CakePHP paginator ignoring order, but only for certain values -