Questions tagged [win32exception]

Win32Exception Class is part of .NET Framework and is used as wrapper of Win32 error codes.

Win32Exception Class is part of .NET Framework and is used as wrapper of Win32 error codes.

81 questions
106
votes
6 answers

.Net Core 2.0 Process.Start throws "The specified executable is not a valid application for this OS platform"

I need to let a .reg file and a .msi file execute automatically using whatever executables these two file types associated with on user's Windows. .NET Core 2.0 Process.Start(string fileName) docs says: "the file name does not need to represent an…
Jyunhao Shih
  • 1,287
  • 2
  • 8
  • 9
32
votes
8 answers

System.ComponentModel.Win32Exception: The operation completed successfully

I am getting this exception sometimes while running my Windows Forms app for a long time: System.ComponentModel.Win32Exception: The operation completed successfully at System.Drawing.BufferedGraphicsContext.CreateCompatibleDIB(IntPtr hdc, IntPtr…
Jakub Kaleta
  • 1,740
  • 1
  • 18
  • 25
24
votes
5 answers

Access is denied exception when using Process.Start() to open folder

I have a winforms application in C# where I have to open a certain Folder. I use System.Diagnostics.Process.Start(pathToFolder); This results in the following exception: System.ComponentModel.Win32Exception (0x80004005): Access is denied at…
IRAndreas
  • 401
  • 1
  • 3
  • 9
20
votes
3 answers

Throwing a Win32Exception

I've been writing a lot of code recently that involves interop with the Win32 API and have been starting to wonder what's the best way to deal with native (unmanaged) errors that are caused by calls to Windows API functions. Currently, the calls to…
Noldorin
  • 144,213
  • 56
  • 264
  • 302
14
votes
6 answers

Win32Exception: The directory name is invalid

I'm trying to run a process as a different user that has Administrator privilege in 2 different computers running Vista and their UAC enabled but in one of them I get a Win32Exception that says "The directory name is invalid" Can anyone tell me what…
mrtaikandi
  • 6,753
  • 16
  • 62
  • 93
12
votes
4 answers

Win32Exception Not enough storage is available to process this command

Through my automated crash collection for MaxTo I got the following crash report: V8.12.0.0 - System.ComponentModel.Win32Exception - :Void UpdateLayered():0 Version: MaxTo8.12.0.0 Exception: System.ComponentModel.Win32Exception Error message: Not…
Vegard Larsen
  • 12,827
  • 14
  • 59
  • 102
10
votes
1 answer

System.ComponentModel.Win32Exception when starting process - file not found, but file exists

I am trying to create a manager for my autostarts. It should read an XML file and then start my programs with a custom delay. For example: Realtek Audio Manager C:\Program…
pascalhein
  • 5,700
  • 4
  • 31
  • 44
8
votes
3 answers

No application is associated with the specified file exception

UnhandledException: System.ComponentModel.Win32Exception: No application is associated with the specified file for this operation at System.Diagnostics.Process.StartWithShellExecuteEx(ProcessStartInfo startInfo) at…
baron
  • 11,011
  • 20
  • 54
  • 88
7
votes
3 answers

Unhandled 'System.ComponentModel.Win32Exception' when using AvalonDock 2.0

I'm using AvalonDock 2.0, and when ever I open a dock container, while on debugging mode the application crash (it works fine when running without debugging). I get the below exception: An unhandled exception of type…
IBRA
  • 1,502
  • 3
  • 24
  • 56
7
votes
2 answers

Diagnosis on "Quota Exceeded" Win32Exception

Most of the time working as a .Net developer gives us the freedom to mess around in our high-level-of-abstraction world, but sometimes reality kicks you in the private parts and tells you to find a man who really understands. I've just had one of…
Sebastian Edelmeier
  • 4,095
  • 3
  • 39
  • 60
6
votes
2 answers

Access denied while getting process path

I am trying to get process path by pid but I'm getting Win32Exception (access id denied). The code looks like this: string path = Process.GetProcessById(pid).MainModule.FileName I have tried using OpenProcess with GetModuleFileNameEx but…
Giorgi
  • 30,270
  • 13
  • 89
  • 125
5
votes
1 answer

A first chance exception of type 'System.ComponentModel.Win32Exception' occurred in WindowsBase.dll

I have a .NET 4.0 WPF project. When I open a FileDialog, choose some files and press the OK button, then I see in the output window this error: A first chance exception of type 'System.ComponentModel.Win32Exception' occurred in…
msfanboy
  • 5,273
  • 13
  • 69
  • 120
5
votes
1 answer

Win32Exception: Access is denied in System.Diagnostics.ProcessManager.OpenProcess()

Firstly, I am a naive developer and have no much indepth understanding of these codes. I am getting access denied in the code block which tries to get the version number of one of the application. Scenario : There is no issue while running the code…
Avishekh Bharati
  • 1,858
  • 4
  • 27
  • 44
4
votes
2 answers

Error 23 is not a valid Win32 application on .resx file

I have a form in my VB>NET project (2010) with some ImageList. Those images are embedded in the list with a form resource in a .resx file as data name="xxxx.ImageStream" mimetype="application/x-microsoft.net.object.binary.base64 When I tried to…
Gabriel Mendez
  • 1,115
  • 1
  • 9
  • 28
4
votes
1 answer

C# System.ComponentModel.Win32Exception (0x80004005): Not enough storage is available to process this command

After running my application (.Net 4.5, 64-bit, WPF) a long time (one to two weeks) I encounter the following app crash: Faulting application name: XY.exe, Version: 2.12.2.2, Time: 0x5bade142 Faulting module name: KERNELBASE.dll, Version:…
Creepin
  • 482
  • 4
  • 20
1
2 3 4 5 6