FERR()

Syntax:

ferr() | ferr!()

The FERR() function returns error information subsequent to the last LOAD or SAVE statement. The function can return a byte or an integer.

If the return value is zero, no error occurred. Otherwise the value will hold the matching KERNAL error code.

Example:

load "myfile",8
err = ferr()
if err = 0 then print "success" else goto load_error
end
load_error:
	print "an error occurred"
	rem ** more error handling **

Example error codes:

Code Error
4file not found
5device not present
8missing file name
9illegal device number
29load error
30break (user pressed break button)

Discussion

Enter your comment. Wiki syntax is allowed:
B​ A U I G
 
This website uses cookies. By using the website, you agree with storing cookies on your computer. Also you acknowledge that you have read and understand our Privacy Policy. If you do not agree leave the website.More information about cookies