473,396 Members | 1,853 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

Process MainModule.Filename gives Exception

Hello,
I'm trying to trap different process using a little c# app I wrote. I'm
having a problem reading the MainModule.Filename on certain processes...such
as when I fire up cmd.exe, I get an exception (Access denied) when I try and
check the MainModule.Filename for this. Also, when FireFox fires I also get
the same error. Other processes show the MainModule.Filename fine.
Does anyone know how I might get around this?

Thanks
Mar 20 '06 #1
0 2159

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Greg Merideth | last post by:
This piece of code creates a fault at the attempt to get the modulename of the process when (in server2k or xp) the code gets to the "System" prcoess. Process machineProcesses =...
7
by: Christopher Attard | last post by:
Hi, How can I obtain the full path for a running process without using WMI? I've tried to use the Process.StartInfo.WorkingDirectory but it's not valid since the process is already running. ...
3
by: Dakkar | last post by:
I want to get the full path of the processes with c# but i dont know how is something like that possible if it is how? Thanks Posted Via Usenet.com Premium Usenet Newsgroup Services...
9
by: DraguVaso | last post by:
Hi, I want my application to bring another application to the Front. I thought best way to do this was by the Process-model: Dim c As Process = Process.GetCurrentProcess() Dim p As Process...
2
by: alvis | last post by:
hi i have a windows service that uses an excell workbook when i create the excell app i cant distroy it after i am finished i am using this code whats wrong? thanks Dim processes1(), p1 As...
6
by: Dubya | last post by:
Hello All I have the following code below that starts an external process batch file. I would like to have the application display a dialog box confirming that the process has ended. When I run...
4
by: Dave | last post by:
I am writing a C# app in which I need to enumerate the processes running on the PC. I have succesfully done this as follows (assuming the app is running on NT4, XP, 2000 or 2003): ...
7
by: xla76 | last post by:
Using WMI I can get the full path of a process on a remote computer: "SELECT ExecutablePath FROM Win32_Process" Without wmi I can get theprocessname and id: For Each ps In...
2
by: Tim | last post by:
Hey guys, I tried to get a process handle with the following code snippet: 00 Process processes = Process.GetProcesses(); 01 if (null != processes && processes.Length 0) 02 { 03 foreach...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.