Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsVB SyntaxEnterprise DevelopmentDatabase AccessControlsCOMWin APICrystal ReportDeploymentGeneralGeneral 2
Related Topics
VB.NET / ASP.NETMS SQL ServerMS AccessOther Database ProductsMore Topics ...

VB Forum / COM / July 2005



Tip: Looking for answers? Try searching our database.

EnumProcesses in library PSAPI.dll not returning all processes

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
aaa - 21 Jul 2005 14:55 GMT
I have tried to use the EnumProcesses function from the PSAPI.dll to retreive
the running processes. However, out of the 69 running processes I had going
it only seemed to find 58. Especially, it didn't return my applications
process information. What is wrong?
Ken Halter - 27 Jul 2005 05:51 GMT
>I have tried to use the EnumProcesses function from the PSAPI.dll to
>retreive
> the running processes. However, out of the 69 running processes I had
> going
> it only seemed to find 58. Especially, it didn't return my applications
> process information. What is wrong?

The absolute best thing you can do is find out why (as mentioned in your
previous post) "There might be situations when my application doesn't close
down properly and leaves one or a few com modules running". There must be a
reason. Since there are so many things you can do that'll cause this and
besides questions about trying to yank the plug on those components, you
haven't given enough information for anyone to help solve the real issue.

The most common things that can go wrong:
Circular References <-- probably the number one cause of components that
won't die

Other things that'll keep a component alive
Any references to that object. An object will die when the reference count =
0
Timers that do any significant work.
All forms must be unloaded.
All automation objects must be closed and set = Nothing
Database objects, closed and set = Nothing

All kinds of things.

Signature

Ken Halter - MS-MVP-VB - http://www.vbsight.com
DLL Hell problems? Try ComGuard - http://www.vbsight.com/ComGuard.htm
Please keep all discussions in the groups..

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.