====== 34 Error Handling ====== ===== Tips and Tricks ===== * **Auto Error Handling** * If you name your VI 'Simple Error Handler.vi' or 'General Error Handler.vi' as its file name, then the auto error handling dialog won't come up. ---- ===== Error Codes ===== ==== Error Ranges ==== * [[https://www.ni.com/docs/en-US/bundle/labview/page/lverror/error_code_ranges.html|Ranges of Error Codes]] * [[https://www.ni.com/docs/en-US/bundle/labview/page/lverror/misc_lv_error_codes.html|General LabVIEW Error Codes]] * [[https://www.ni.com/docs/en-US/bundle/labview/page/lvhowto/def_cust_errors.html|Defining Custom Error Codes]] -> Use the range reserved for user-defined errors (500000 – 599999). ==== Error Code Files ==== [[https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000P83iSAC&l=de-DE|Where Are LabVIEW Error Code Files Located? ]] ==== Error Code Editor ==== The Error Code File Editor (Tools->Advanced->Edit Error Codes) provides a simple GUI for creating and editing a custom error XML files. See https://labviewwiki.org/wiki/Error_Codes_Editor for details. ==== Distributing Error Codes ==== If you are creating a stand-alone application (EXE), refer to the [[https://www.ni.com/docs/en-US/bundle/labview/page/lvhowto/dist_error_code_files.html|Distributing Custom Error Codes in Text Files]] topic in the LabVIEW Help. The installer build includes all error code files from ''\project\errors'' and ''\user.lib\errors'' and installs them in the ''\LabVIEW Run-Time\X.X\errors'' directory.