471,355 Members | 1,608 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,355 software developers and data experts.

Pause COM object

Hi

I am using one API to do some process for me, but unfortunately API dont
have a option of pause the process and resume it back. How can i do this
using C#

API take more then 2 hours in processing and takes 100% CPU usage, I want a
option so that i can pause the COM to work and resume when required.

Thanks in advance.


Feb 3 '06 #1
1 1395
OBINT,

If the object doesn't expose this functionality, then you really don't
have a choice.

What you might want to do is run the object in another thread and set
the Priority property to a lower value. This will increase processing time,
but should make your system more responsive.

Additionally, you could have a separate process run the COM object, and
then set the priority of the process itself to be low.

The best thing to do in this situation would be to re-engineer the COM
object to have a "pause" method, or to make it more efficient/less
consuming. You can do this either in .NET or in unmanaged code, but that
requires the most work. It might also be the best solution.

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

"OBINT" <pr********@yahoo.com> wrote in message
news:%2****************@TK2MSFTNGP09.phx.gbl...
Hi

I am using one API to do some process for me, but unfortunately API dont
have a option of pause the process and resume it back. How can i do this
using C#

API take more then 2 hours in processing and takes 100% CPU usage, I want
a
option so that i can pause the COM to work and resume when required.

Thanks in advance.

Feb 3 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

8 posts views Thread by Scotter | last post: by
reply views Thread by Andrew | last post: by
11 posts views Thread by Paminu | last post: by
19 posts views Thread by C# Learner | last post: by
8 posts views Thread by Wim | last post: by
3 posts views Thread by nma | last post: by
reply views Thread by XIAOLAOHU | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.