Click here to Skip to main content
15,886,199 members
Articles / Desktop Programming / MFC

Process viewer

Rate me:
Please Sign up or sign in to vote.
4.94/5 (104 votes)
9 Mar 2008CPOL9 min read 455.5K   22K   294  
Lists out the details of running processes in a system, loaded drivers, loaded dlls, version of each dll and process, process times, command line, owner, priority, GDI resource usage, privileges, loaded symbols, window heirarchy, autostart app finding and more.
#ifndef _MODULE_H_
#define _MODULE_H_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#include "FileVersionInfo.h"
#include <TLHELP32.H>

class Module
{
    public:

        Module();
        virtual ~Module();

        // Set module entry
        void SetModuleEntry32( const MODULEENTRY32& stModuleEntry32_i )
        {
            m_stModuleEntry32 = stModuleEntry32_i;
        }

        // Return reference to module entry
        const MODULEENTRY32& GetGetModuleEntry32() const
        {
            return m_stModuleEntry32;
        }

        // Return module file handle
        const HMODULE& GetModuleHandle() const { return m_hModuleHandle; }

        // Clear internal members
        void Clear();

    private:

        // Module handle
        HMODULE m_hModuleHandle;

        // Entry for a module
        MODULEENTRY32 m_stModuleEntry32;
        FileVersionInfo m_fviVersion;

};// End class Module

#endif // _MODULE_H_

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer Microsoft
India India
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions