This content is not available in your preferred language.

The content is shown in another available language. Your browser may include features that can help translate the text.

Troubleshooting LabVIEW Crashes

Updated Jul 12, 2022

Reported In

Software

  • LabVIEW

Issue Details

  • While navigating the LabVIEW Development Environment, LabVIEW crashed and displayed the following error: LabVIEW 20xx encountered a problem and needs to close. You can help us diagnose and fix this problem by sending this report directly to National Instruments.
 
  • LabVIEW crashes with no errors when I close a VI that I have created. 
  • LabVIEW crashes with no errors when hovering over items in a project after updating Windows 10 to version 21H2. 
  • How can I find the cause for my LabVIEW crash?

Solution

Initial troubleshooting steps for LabVIEW internal errors and crashes:

  1. Send the crash report to NI via the LabVIEW Crash Reporter dialog box.
    • Add any relevant information that will aid NI in diagnosing the crash.
  2. Determine if you can reproduce the crash consistently.
    • This will make diagnosing the source of the crash easier. 
    • If you can reproduce the crash, then try searching the KnowledgeBase and the NI Community for similar crashes. Include the hex code and what you were doing when the crash occurs.
  3. Install the latest LabVIEW patch.
  4. Check the LabVIEW Known Issues list for your LabVIEW version.
 

Further troubleshooting steps:

  • If the crash occurs when trying to launch the LabVIEW Development Environment, try to fully shut down and restart the affected machine before trying subsequent steps.
  • If you are using Timed Structures on non-deterministic environments like Windows, substitute them with regular (non-timed) structures. 
  • Try to narrow down the source of the warning.
    • Reduce the code and the amount of hardware used to create the smallest reproducing case of the crash.
    • If you can eliminate the parts that are not related to the crash, you are more likely to find the root cause of this specific crash. Please see the following troubleshooting steps to help in doing this:
      • Avoid using classes inside Libraries, if this is the case, move the classes out of the libraries.
      • If the crash happens with an executable, check if the same behaviour occurs when running the VI from the LabVIEW development environment. Doing this may point to an issue with the Run-Time Engine.
      • Try using a Diagram Disable Structure to disable parts of your code. This can help narrow down where in your code the crash is happening.
      • Try removing all hardware. If you still see the crash, then you can continue troubleshooting the software. If removing the hardware fixes the crash, then you can narrow the cause to the hardware. Try using a different kind of hardware to see if the crash is specific to the type of hardware.
      • Check if you see the same behaviour on a different computer. The crash could have something to do with the environment of the computer.
  • Monitor memory to check for memory leaks.
    • If using hardware, ensure that you are closing every memory reference. Any misuse of the references could cause a memory leak.
  • Use WinDbg to troubleshoot the crash.
    • If the crash is reproducible, then attach this tool to the LabVIEW process and cause the crash to happen again. This tool can give you a more in-depth look at the source of the crash.
  • Make sure that all the error clusters are connected and being monitored. An error may have occurred earlier that you are unaware of.
    • Error numbers are there to specify what went wrong and can be searched for in the Explain Error dialog box (Help» Explain Error...) to find an explanation about the error.
  • If you are using .NET framework or DLLs, try removing them to see if the crash still happens. The DLL could be where the crash is happening.
  • If the crash occurs consistently with just one VI, try copying the entire contents of its Block Diagram to a new VI.
    • This can remove corruptions that can cause crashes.
  • Mass compile your VIs.
    • If you upgraded LabVIEW from an earlier version, you may have some older VIs that were not updated.
  • The crash could also be happening because of an "Insane Object" or "fsane.cpp" error in your code.
  • If the crash is occurring in an executable, ensure all necessary drivers are installed on the deployment machine.
  • Implement your own logging to gain more information on where the crash may be occurring.
  • Turn off the firewall and try to run your project.
    • Some antivirus software, such as SentinelOne, contain DLLs that cause LabVIEW to crash. 
  • Ensure you are not exceeding the maximum size of the block diagram or front panel
  • Use LabVIEW Desktop Execution Trace Toolkit to perform advanced debugging using dynamic code analysis.
  • If you updated Windows 10 to version 21H2, try to repair the LabVIEW installation.
  • Sometimes when you press any combination of keyboard keys or keyboard keys with the mouse it causes Windows to run some third party software that could cause LabVIEW to crash.


Additional troubleshooting steps:

If the root cause of the crash can be determined, the next step is to find a workaround or reproduce the crash on the smallest possible scale. If it is a LabVIEW bug, then a Bug Report can be filled out by contacting NI Technical Support. Attach an example VI that demonstrates the crash as well as any supplementing files obtained from the above steps. This will help our Technical Support Engineers replicate and best understand the problem.

It's possible that the issue is related to a corruption of the software or even the operating system. If you've tried the troubleshooting steps mentioned above and were unable to resolve the problem, consider reimaging the computer. 

Additional Information

What is a LabVIEW internal error?

A LabVIEW internal error is an indication that something wrong or unexpected has occurred within LabVIEW. Depending on the level of severity, you may receive an error dialog immediately or possibly later, when you exit or restart LabVIEW. The three severity levels are DAbort, DWarn, and DWarnInternal.
  • A DAbort is unrecoverable and LabVIEW exits immediately.
    • This avoids possible further corruption and you will see a LabVIEW Crash Report dialog box similar to the one above.
  • DWarn and DWarnInternal are recoverable errors and will not cause LabVIEW to exit, but they are still unexpected and need to be reported.
    • You may see an Internal Warning Report dialog box when exiting from LabVIEW, depending on your LabVIEW settings.