|
Posted on
2008-09-18 23:16
烈火123
阅读( 292)
评论()
编辑
收藏
举报
- Application.StartupPath
- Environment.SystemDirectory;
- Environment.CurrentDirectory;
-
-
- Process[] allProcesses = Process.GetProcesses();
- foreach(Process p in allProcesses)
- {
- if(p.ProcessName.Equals("Idle"))
- {
- continue;
- }
- labelPN.Text = theNode.processInfo.ProcessName;
- labelPID.Text = theNode.processInfo.Id.ToString();
- labelSO.Text = theNode.processInfo.StartTime.Date.ToString();
- labelNOT.Text = theNode.processInfo.Threads.Count.ToString();
- ProcessModuleCollection allModules = null;
- try
- {
- allModules = p.Modules;
- }
- catch
- {
- continue;
- }
- ProcessModule[] modules = new ProcessModule[allModules.Count];
- int i = 0;
- foreach(ProcessModule m in allModules)
- {
- modules.SetValue(m, i++);
- }
- labelMN.Text = theNode.moduleInfo.ModuleName;
- labelCN.Text = theNode.moduleInfo.FileVersionInfo.CompanyName;
- labelLFF.Text = theNode.moduleInfo.FileVersionInfo.FileName;
- labelFV.Text = theNode.moduleInfo.FileVersionInfo.FileVersion;
- if(!theNode.moduleInfo.FileVersionInfo.FileDescription.Equals(""))
- labelFD.Text = theNode.moduleInfo.FileVersionInfo.FileDescription;
- else
- labelFD.Text = "<None>";
- DateTime timestamp = File.GetCreationTime(theNode.moduleInfo.FileVersionInfo.FileName);
- labelFT.Text = timestamp.ToString();
- FileInfo fileInfo = new FileInfo(theNode.moduleInfo.FileVersionInfo.FileName);
- labelFS.Text = fileInfo.Length.ToString();
- }
-
|