Windows 10: File open dialog crashes randomly in WPF application

Discus and support File open dialog crashes randomly in WPF application in Windows 10 Gaming to solve the problem; Hi,In my application file open dialog crashes randomly in WPF application based .Net framework. In event viewer logs, it reports Access violation... Discussion in 'Windows 10 Gaming' started by Mathews George, May 22, 2025 at 1:13 PM.

  1. File open dialog crashes randomly in WPF application


    Hi,In my application file open dialog crashes randomly in WPF application based .Net framework. In event viewer logs, it reports Access violation exception in ntdll.dllThis issue occurs only with new style file open dialog box for file dialogs from both Microsoft.Win32 and System.Windows.Forms.This issue is not happening with old style file open dialog boxes.when using FileOpenDialog from System.Windows.Forms with AutoUpgradeEnabled flag set as false.On verifying by enabling Application verifier using gflags application, issues are reported in event viewer on closing the file open dialog b

    :)
     
    Mathews George, May 22, 2025 at 1:13 PM
    #1
  2. MrSeanKon Win User

    Enable visual styles in WPF application

    EUREKA!

    Steps:
    1) I made a Windows form (HostWPF namespace, Form1 is the form).
    2) I added a reference => System.Windows.Forms.Integration which contains classes that enable interoperation between the Windows Forms and WPF technologies. When you use System.Windows.Forms.Integration classes, you can host Windows Forms controls on WPF pages, and WPF elements in Windows Forms-based applications.
    3) Then added a control (damn Vi$ual $tudio 2010 does not allow to add a WPF window) but after adding I edited the XMAL code in the way I want *Wink File open dialog crashes randomly in WPF application ;)
    4) The next steps are simple. Download the first attachment. But => see the photo.
    It crashes!!!!!
    5) Finally???
    We must use System.Windows.Forms.Application.Exit(); command because the WPF window behaves like a classical Windows Form.
    Download the second attachment. Note that the Windows form's name is Initial.
    Enjoy!
     
  3. Applications crash during file open dialogs

    Windows10 Home

    Version 10.0.17134

    In Chrome and in Cybershot PowerDirector17 (a video editor application), when I try to change a path (switch from one directory to another) in a file open dialog, the application crashes. It's so bad I don't use Chrome (Liking Edge a lot) but I can't do
    without the video editor so I need to find an answer on how to prevent this from happening. Curiously, the problem does not happen when using file dialogs in Edge, nor in the majority of applications on my PC. It's really just these 2 apps. Would appreciate
    any suggestions.
     
    FredPeachman, May 22, 2025 at 1:17 PM
    #3
  4. Denno Win User

    File open dialog crashes randomly in WPF application

    File Open/Save Dialog causing applications to crash

    Seemingly ever since the Windows 10 Creators Update installed itself on my computer, I've been having issues when using the File Open/Save dialog. If I try and open a file, save a file, or upload a file to attach to an email, the application that I'm using will crash (whether it's Chrome, Word, Paint etc). Edge, however, works fine and weirdly, Firefox also works fine.

    I have been doing some debugging, trying to figure out what it could be, but I'm running out of things to try.

    I've tried the following:

    • Resetting folder views to default
    • Enabling "Show all Folders" in Folder View Settings
    • Starting computer in safe mode (where the dialog would work just fine)

    I have also run some tests using MS Paint. I downloaded an application called DebugDiag 2, and had that watch the mspaint process to capture the exceptions thrown when the application would crash. These are the ID's of those exceptions:

    • 0XC000001D
    • 0XC000041D

    Still using MS Paint as my test application, if I ran it as an adminstrator, I was able to use the File Open/Save dialog perfectly fine, but closing the application then reopening as a normal user would then end with the application crashing upon trying to open a file.

    Another thing I've noticed is that when I first sign into Windows, I have about 30 seconds where I can open MS Paint, and be able to use the File Open/Save dialog just fine. After that time, if I close the dialog and then try to use it again, the application will crash.

    I've read online that this issue is sometimes caused by the File Open/Save dialog trying to show a folder that no longer exists, or is on an unreachable network drive. So with that in mind, I have restarted my computer (getting that 30 seconds of grace when I first sign in) to be able to open MS Paint, and save a new file to my downloads folder, in the hopes that it would update the "last used folder". Unfortunately, this didn't solve the issue.

    Is there anything else I can try?
     
Thema:

File open dialog crashes randomly in WPF application

Loading...
  1. File open dialog crashes randomly in WPF application - Similar Threads - File open dialog

  2. File open dialog crashes randomly in WPF application

    in Windows 10 Software and Apps
    File open dialog crashes randomly in WPF application: Hi,In my application file open dialog crashes randomly in WPF application based .Net framework. In event viewer logs, it reports Access violation exception in ntdll.dllThis issue occurs only with new style file open dialog box for file dialogs from both Microsoft.Win32 and...
  3. Application crashes when open file dialog appears and a folder is selected

    in Windows 10 Gaming
    Application crashes when open file dialog appears and a folder is selected: I experience this issue with two programs:- Mozilla Thunderbird: when i'm trying to attach a file to an email, the dialog windows opens and the moment i select a folder the application crashes - ST Cube Programmer from ST Microelectronics: happens the same, when the file...
  4. Application crashes when open file dialog appears and a folder is selected

    in Windows 10 Software and Apps
    Application crashes when open file dialog appears and a folder is selected: I experience this issue with two programs:- Mozilla Thunderbird: when i'm trying to attach a file to an email, the dialog windows opens and the moment i select a folder the application crashes - ST Cube Programmer from ST Microelectronics: happens the same, when the file...
  5. Issue with KB5017262 & KB5017270 cause WPF application to crash

    in Windows 10 Installation and Upgrade
    Issue with KB5017262 & KB5017270 cause WPF application to crash: Hello,we are having a trouble since the September cumulative update, our customers reporting that since the upgrade of the above KB, our WPF application crash with the below error:System.Reflection.TargetInvocationException: Exception has been thrown by the target of an...
  6. Issue with KB5017262 & KB5017270 cause WPF application to crash

    in Windows 10 Gaming
    Issue with KB5017262 & KB5017270 cause WPF application to crash: Hello,we are having a trouble since the September cumulative update, our customers reporting that since the upgrade of the above KB, our WPF application crash with the below error:System.Reflection.TargetInvocationException: Exception has been thrown by the target of an...
  7. Issue with KB5017262 & KB5017270 cause WPF application to crash

    in Windows 10 Software and Apps
    Issue with KB5017262 & KB5017270 cause WPF application to crash: Hello,we are having a trouble since the September cumulative update, our customers reporting that since the upgrade of the above KB, our WPF application crash with the below error:System.Reflection.TargetInvocationException: Exception has been thrown by the target of an...
  8. Unable to launch WPF application, crashes with AccessViolationException when accessing...

    in Windows 10 Network and Sharing
    Unable to launch WPF application, crashes with AccessViolationException when accessing...: Hi,recently we seeing our application is crashing because of the AccessViolationException when accessing the font collection. This is happening in very few VMs upgraded to Win10 21H2. Event viewer has below callstack. We tried rollback the windows update, but no use. still...
  9. Applications crash during file open dialogs

    in Windows 10 Network and Sharing
    Applications crash during file open dialogs: Windows10 Home Version 10.0.17134 In Chrome and in Cybershot PowerDirector17 (a video editor application), when I try to change a path (switch from one directory to another) in a file open dialog, the application crashes. It's so bad I don't use Chrome (Liking Edge a lot)...
  10. Applications crash when using system file dialog (opening/saving)

    in Windows 10 Support
    Applications crash when using system file dialog (opening/saving): I first noticed this in Chrome, thinking it was an issue with Chrome 57 (I couldn't attach files to emails because when I clicked to choose my file, Chrome would just crash). I've since noticed that it is a Windows issue after I tried to save a Photoshop image that I had...