CodeVerge.Net Beta


   Explore    Item Entry    Members      Register  Login  
NEWSGROUP
.NET
Algorithms-Data Structures
Asp.Net
C Plus Plus
CSharp
Database
HTML
Javascript
Linq
Other
Regular Expressions
VB.Net
XML

Free Download:




Zone: > NEWSGROUP > Asp.Net Forum > general_asp.net.security Tags:
Item Type: NewsGroup Date Entered: 12/24/2004 3:48:19 PM Date Modified: Subscribers: 0 Subscribe Alert
Rate It:
(NR, 0)
XPoints: N/A Replies: 1 Views: 43 Favorited: 0 Favorite
Can Reply:  No Members Can Edit: No Online: Yes
2 Items, 1 Pages 1 |< << Go >> >|
rox.scott
Asp.Net User
GetProcessesByName() fails intermittantly12/24/2004 3:48:19 PM

0/0

I am trying to get the ProcessID of a process that I have just started.
It is within ASP.NET, but with impersonation of non-Admin user.
If I call 10 times in the same request, it succeeds about 80%.
2 of the 10 will give System.ComponentModel.Win32Exception: "Access is denied"
I saw something posted about needing to have perf counters enabled on any enumerated process, is this true ??

My code goes something like this:
        sAp as String = "EXCEL"    ' for example ...

sHandle = FindWindow(sAp, sGuid).ToString
Try
For Each proc In System.Diagnostics.Process.GetProcessesByName(sAp) ' this line excepts
If proc.Handle.ToString = sHandle Or proc.MainWindowHandle.ToString = sHandle Then
iRes = proc.Id
Exit For
End If
Next
Catch e As Win32Exception
Throw New Exception("AHA!!")
Finally
ExcelProcessID = iRes
End Try
rox.scott
Asp.Net User
Re: GetProcessesByName() fails intermittantly1/4/2005 8:45:39 PM

0/0

This error goes away on system reboot.
Anyone know why?
What steps can I perform manually to reset this problem (presumably related to performance counters) without reboot?
2 Items, 1 Pages 1 |< << Go >> >|


Free Download:


Web:
microsoft.public.dotnet.security: By Thread RE: GetProcessesByName() fails intermittantly with Access Denied rox.scott (01/ 04/05); Re: WSE 2.0 Kerberostoken creation on IIS 5.0/win2k fails shikari ...
reloaded from state file triggered a build (ForceBuild) Buildfile ... GetProcessesByName(String processName, String machineName) at System. ... ShouldOnlyDisposeOnce : This is intermittently failing, I think due to some evil ...
TheMSsForum.com >> VB >> Excel Process ID - The Microsoft Software ... The exact same code, it works in the Forms version, fails in the Service version . ..... Dim localByName As Process() = Process.GetProcessesByName("excel") ...
microsoft.public.dotnet.general: By Thread Re: GetProcessesByName on Server2003 terminal server session Russell ...... RE: trace output in page goes on/off intermittently tom wisnowski (10/05/04) ...
Fixes that are included in the Update Rollup 1 for Microsoft ... GetProcesses() procedure fails on a computer that is running Windows 2000 ...... Computer intermittently stops responding and a Stop 0x000000C2 error occurs ...
TheMSsForum.com >> Framework >> BitArray vs. BitVector32 - The ... The application fails on a Decrypt with a "bad key" error in the "Windows ..... the program runs on a Windows Server 2k3 machine and intermittently crashes. ...
microsoft.public.dotnet.framework: By Thread Type.GetType fails on Enum types? Mattias Sjögren (08/20/04) ...... Re: Windows service which intermittently sleeps eventually never w Phani (08/04/04) ...
Windows 2000 articles, fixes and updates - letter T GetProcesses() procedure fails on a computer that is running Windows 2000 Q823642 .... 883514 Terminal server host applications may intermittently stop ...
Archived EggHeadCafe Forum Posts How to tell version of MSXML ... Call succeeds in debug, fails in full compile...-Visual Basic (01-08 11:06 AM) ..... Image links intermittantly breaking-ASP.NET (01-22 11:27 AM) ...
Java 2 Technology Edition Version 1.4.2 Diagnostics Guide for z ... fails and the Garbage Collector must perform a garbage collection. ...... If the system intermittently sees high CPU usage for the process in which Java is ...




Search This Site:










cannot find the source-path specified

change loginstatus params for the login.aspx

forms authentication processing

com - access denied

using a user class library in 2.0

a comparaison of jsf (javaserver faces) and webforms/asp.net

adding file extension to url

dotnetnuke debugging

habahaba dnn skin port, anyone?

validation and error messages in v.2

it appears that your menu dll is out of sync with your script file

createuserwizard + add profile item question

type expected

store windows credentials when logging into fpse enabled site with vs.net 2005

css and the tilde...

not receiving any emails??

masterpage,actions, and url rewriting

aspnetdb.mdf

28 gig sql transaction log..

asp c# toolbox control

treeview long string of text need breaks within??

ajax with .net framework 1.1

generic control binding function

ibuyspy and visual c# standard

either bof or eof is true

compiling vb.net file containing dataset

dnn 3.06 file manager decompress zip

please help, how to make dataset's information accessible in other procedures in webform

sql query control

string bug in vs2005 ?

 
All Times Are GMT