fraizor Posted July 23, 2023 Posted July 23, 2023 Hello i have something like this in my code $Fopen = FileOpenDialog("Select dictionary file, Should be seperated with | sign",@ScriptDir, "TSV (*.tsv)") if @error then MsgBox(16, "Error", "Error selecting TSV file, Error code: " & @error) Exit Else _FileReadToArray($Fopen ,$DictFile, 0, "|") if @error then MsgBox(16,"Error", "Error processing Dictionary file... Error code: " & @error) Exit EndIf EndIf The msg box works when there is an issue , however error code is not really good for the user ... i know that i can manually map every code to a text error , however i think the explanation in the help file would be enough... is there is a way to tell Autoit to show the error in the help file instead of error code ? AutoFox, A Modern, Simple, No dependency, Noob friendly yet powerful Firefox UDF !
Andreik Posted July 23, 2023 Posted July 23, 2023 No, at least not for native functions. Since each function set different error codes you have to implement this manually if you want to display the error message instead of error code. For WinAPIs you can call _WinAPI_GetLastErrorMessage() and you will get the error message.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now