Ejemplo n.º 1
0
        public static void chkProcessMemory2(Log log)
        {
            ProcessMemory       mem;
            Diag::ProcessModule mod = GetNotepadModule(log, out mem);

            if (mod == null)
            {
                return;
            }

            Module module = new Module(mem, mod);

            Forms::Form         f    = new System.Windows.Forms.Form();
            Forms::PropertyGrid grid = new System.Windows.Forms.PropertyGrid();

            grid.Dock           = Forms::DockStyle.Fill;
            grid.SelectedObject = module;
            f.Controls.Add(grid);
            f.ShowDialog();
            f.Dispose();
        }
Ejemplo n.º 2
0
        public static void chkProcessMemory3(Log log)
        {
            const string  TARGET = "notepad.exe";
            ProcessMemory mem    = new mwg.InterProcess.ProcessMemory(TARGET);

            if (!mem.Available)
            {
                log.WriteLine("notepad.exe なるプロセスは起動していません。");
                return;
            }

            Forms::Form f = new System.Windows.Forms.Form();

            f.Size = new System.Drawing.Size(700, 500);
            ProcessView view = new ProcessView();

            view.Dock = Forms::DockStyle.Fill;
            view.SetProcess(mem);
            f.Controls.Add(view);
            f.ShowDialog();
            f.Dispose();
        }