Complete listing of MaxScript Error Codes Open in a new tab


1 - Blank page error
Cod Msg  
None None
 
The browser displays a blank page.
Expose the HTML code of the page (using the browser tools) and inspect it: error code should be located at the bottom of the page.
Normally just right-click on the page and choose View Source HTM or a similar option (depending on browser).
2 - Standard errors
Cod Msg  
R0004 ERROR R0004: invalid parameter type
JLUSERER.PRG interrupted
line(10), proc USERERROR
A parameter passed to a command or used into a statement is of wrong type or is missing.
If the parameter was a fieldname means there is no matching fields in the table structure.
Try expose the source code of the page and where exactly the error occured:check out the lines before the error message.
If error occured in a portion of code involving a library call check out the library path and name and be sure the library exists.
R0005 invalid number of parameters Check the parameters you passed to the function: parameters must be separated by commas. If you want to omit some parameter your function must incorporate the code to handle missing parameters.
R0006 Invalid picture Some functions expect a picture (a parameter mask): you must provide it as a string.
R0007 ERROR R0007: variable not defined: VARIABLE_NAME
The var is not defined. It happens often when a UDF (user function) receives the wrong parameter or field name (or no parameters at all).
Notice that is an error message concerning the parameter(s) passed, not the function itself (check parameters passed at runtime).
R0008 ERROR R0008: type conflict: =
 
A string was passed when expecting a number or date, or the other way round: try to the universal convertor functions zz() and c2n() to isolate the problem

 

R0009 invalid SELECT Check if the ALIAS for your table is in use and / or if you have a table open in the area you want to select
R0010 ERROR R0010: invalid ALIAS _JSRTWRK If sorting a table:key fieldname is wrong or target is not available (could not be created)
R0011 ERROR R0011: unable to open database table Wrong path for database. Check the value of the path you specified. If no path was specified in the command USE then check the value returned by MspConfigVar("DATADIR")
R0012 invalid DBF file Check the DBF type: only "pure" DBF tables are supported (DBF level 3).
R0013 ALIAS not allowed in assignments Aliases are pointers to memory areas, not data types. Try to use a macro evaluation.
R0014 ALIAS not allowed in ARRAY Arrays cannot store aliases, because aliases are pointers to memory areas, not data types.
R0015 variable is not ARRAY Your code is trying to access a variable that is not an array.
R0016 ARRAY not declared Your code is trying to access an array element while the variable you're using is not an array.
R0017 invalid ARRAY element Your code is trying to access an array element that not exists: check the lenght of the array or the that the value specified by your code is valid.
R0018 database file is not available (A) - Table could be locked by the operating system or you may not have R/W permissions for it (
Under Windows2008 and above check if DBFree has full control over the folder where you stored databases. Try to assign full permissions to EVERYONE to your DATADIR)
(B) - The record you're trying to write to is filtered out by a SET FILTER statement active at the moment you try to access the record or (C) - the cursor is pointing to a record wich does not exist (either in the active index or phisically in the database table, i.e. it may have wrong record number)
R0019 invalid record number Your code is trying to access a record number out of range, either because is phisically not in the table or because is not indexed. Check if the value you specified is more than zero and less than reccount(). 
R0020 write error File could be locked by the operating system or you may not have R/W permissions for it.
Under Windows2008 and above check if DBFree has full control over the folder you want to use and try to assign full permissions to EVERYONE to it.
R0021 invalid SKIP Invalid skip or bof()/eof(): try to USE the table without indexes to see if the error disappears. If so rebuild indexes or carefully inspect your code for incongruency (i.e. tryng to move the record pointer against the rules adopted by the index key).
R0022 all work areas are in use You're opening too many files (tables and indexes) in your page. This limit is defined by the webserver and operating system in use. DBFree can handle no more than 255 files in a single web page, including the page itself, libraries, memory files,data files and so on. Javascript files are handled browser-side so should not be taken into account.
R0023 invalid COLOR Obsolete.
R0024 invalid DATE Check that the value of the variable is a valid calendar date (i.e. November 31 is not).
R0025 invalid negative number in expression Self explanatory
R0026 field not found You specified a field name that does not exist: this error is common while determining field names at runtime by using a macro evaluation. Print out on the web page the results and check if names are built correctly. Also be sure that the correct table is open in the current work area before trying to depict field names.
R0027 invalid parameter type Check the function you are calling and the data type it is expecting to receive.
R0028 cannot update the file
    This error can arise in several different cases:
  • File is somehow locked by the operating system
  • Path of the file (especially LOG files) does not exists or is mistyped
  • Query string expands to an incoherent statement: insert a comment int the code to check what is actually sent to query
  • You may not have R/W permissions for writing the requested file or folder:
    Under Windows 2008 and above check if DBFree has full control over the folder you want to use and try to assign full permissions to EVERYONE for that folder
R0029 number truncated on REPLACE Check the numeric target field or round down the value you're trying to pass to it. You may also need to modify the record structure adding more digits to host the values.
R0030 record too big Record with more than 50 fields may result inpractical.
R0031 too many gets Obsolete
R0032 too many prompts Obsolete
R0033 too many index keys Keep less than 10 indexes for each table.
R0034 too many indexes for work area Keep less than 10 indexes for each table in a given area (i.e. with same alias).
R0035 area invalid or corrupt index file header Check the alias you are using for mistyping, for passing a number instead of a string and viceversa. Also check that the table actually has a valid index selected.
R0036 cannot read root page Check DBFree configuration: the variable to check at runtime (inside the HTML code of the page) is _WEBROOT
R0037 cannot create index file Check the index key for mistyping or specificating an invalid combination of values. Be sure the field you are indexing actually exists. Also check that the table to be indexed is not filtered.
R0038 invalid index key lenght Index keys should be shorter than 20 characters. Only character data tyoes (strings) are allowed. If you need to index on different data types specify a convertions function for it.
R0039 invalid index key type: must be character Index keys should be only of character data tyoes (strings). If you need to index on different data types specify a convertions function for it.
R0040 index not created ad UNIQUE: regenerate it Unique clause violation error: regenerate the index specifying the correct UNIQ key. Also check that values already present in the table are consistent with the key.
R0041 no database table in use Check if the table is open before trying to access it, for example by using the alias() function and checking that return a string (i.e. the name of the table).
R0042 overflow while accessing index Table content has been modified while the index was not in use adding records. Regenerate the index.
R0043 underflow while accessing index Table content has been modified while the index was not in use deleting records. Regenerate the index.
R0044 insufficient memory for indexing Table is too big (too many records) to complete the reindex procedure int the TTL (time to live) of the page. IF you cannot extend the TTL (modifying web server settings) try to use a separate page and an Ajax call to perform the action or to pass the page to the CLI utilities for indexing the file in the background. Many maintenance routines can't be performed inside a web page because of the expiring time forced by browser.
R0045 index already in use Check your code: maybe some function of the framework already opened that index. Make a check using indexkey() and indexord() before to attempt to set the index.
R0046 Internal function only Obsolete
R0047 ERROR R0047: index incompatible with database
  1. You try to reindex a table that contains empty records for the index key field. Fill the empty key field with some arbitrary value before to reindex
  2. Index malformed or created/maintained by another driver (i.e. created for CLipper and read with MAx, etc).
This error also occurs when using an index not updated (i.e. when you added records to the table without its index open)
R0048 too many PRIVATE variables  
R0049 ERROR R0049: procedure/function not found: <PROCNAME> Library error: the requested operation need a procedure or function that is not included into the emulation library in use (usually clipper2.max) - it happens often when invoking interactive Xbase commands not well-emultated on the web like SORT or APPEND FROM, EDIT, BROWSE and the like
R0050 too many RENVARs DBFree CLI runtime only
R0051 cannot access the printer device DBFree CLI runtime only
R0052 too many TRANSLATEs  
R0053 printer not available DBFree CLI runtime only
R0054 too many WGETs DBFree CLI runtime only
R0055 invalid command while READ is active DBFree CLI runtime only
R0056 too many GET levels DBFree CLI runtime only
R0057 scope not allowed  
R0058 ERROR R0058: could not open the file The filename is not valid: if it was passed as a variable between parenthesis try to substitute it with the macro operator (&)
R0059 read file error File is locked by Windows, notably because is open into another program or its internal viewer. This may also happen when you don't have permissions for accesing the file.
R0060 error on execution DBMAX only
R0061 executable file not found DBMAx only
R0062 insufficient memory to execute Obsolete message
R0063 no active index You issued an idexed search like seek() or find  without setting an index first.
R0064 cannot delete file  
R0065 invalid numeric value for operation You passed a non-numeric value to a command that expects a number as parameter or clause
R0066 too many fields to AVERAGE  
R0067 too many fields to SUM  
R0068 uniqueness violation this happens when you specified the clause unique in a statement like index on and then you try to add a duplicated key record
R0069 CONTINUE failure  
R0070 LOCATE not specified  
R0071 missing FOR clause  
R0072 ** ERROR R0072: error on creation of database table The path for creation of a new table with CREATE command does not exist. Create the folder before to attempt to create a table in it. You can also consider to use the md(pathname) function to do so.
R0073 no indexes in use you issued a command like set index to file but there si no index set in the use command
R0074 error on open of Memo (DBT) file  
R0075 DBF has invalid header Check if the DBF is of level 3 (this error arises when you manipulate the file with dBase Plus/Fox, add, delete fields or modify field lenght or type). Simply editinf fields does not cause errors. Adding or deleting records with other programs requires reindexing (if indexes exists).
R0076 error on creation of Memo (DBT) file  
R0077 FIELD already exists in record  
R0078 Memo (DBT) file structure corrupted  
R0079 database table must be opened exclusive For some commands to operate it is necessary to get exclusive access: just use the clause exclusive in the statement and check for any error before to attempt the operation
R0080 too many files Obsolete message
R0081 invalid TONE() frequency Obsolete message
R0082 Record locking required Always use rlock()...unlock before attempting to write to a record to avoid this problem
R0083 File locking required Use flock(2) ...unlock
R0084 Old index file format: rebuild it This happens only when you are using multiple drivers in the same page. Always use the same ODBC driver within a given page. If you need multiple drivers to work side by side in the same page just embed multiple pages, one pr driver, within one by using iframes.
R0085 cannot open MAX file  
R0086 Error on read of MAX file  
R0087 Corrupt MAX file structure  
R0088 too many routines in single MAX file You reached the maximum size of compiled code. This may also happen when you have lot of static code inside the body of the functions. A viable solution is to store large texts on external text file and load them in the body of the functions only at rentime.
R0089 procedure redefinitions A function or procedure is conflicting with another (they have the same name)
R0090 MAX file obsolete: recompile it The executable is older than one or more source files. Remove sources from folder or recomplie.
R0091 Invalid MAX file format: not compiled for Web Did not use the option web() or your initlib() refers to an obsolete library
R0092 Invalid MAX file format:compiled for Web Did not use the correct library (DBMAx requires DBD library when used for desktop applications)
R0093 Only one OXBC connection allowed  
R0094 Feature available only on DBMAX  
R0095 ERROR R0095: interrupted: Session Timed Out Streaming of data from server interrupted. Either the query is too complex or the amount of data is too large and browser timed out. Semplify the query so to process less records. Timeout is set by the web server and comunicated to browser: try to increase it slightly.
R0101 Error R0101 : Invalid Query String
  1. The file you are calling does not exists on destination
  2. Malformed string passed on the URL (probably passed special chars ? and & passed togheter, or two & aside). Right sintax is pagename.msp?VAR1=value&VAR2=othervalue&VARX=values - all values are passed as string (and must be converted by the recipient page)
Error R0101 :data type mismatch in expression Concatenation error in a string. Convert all values to string type before concatening.
R0102 ERROR R0102: invalid array construction:
 
Error in reading the array: usually occurs when you try to acces an element that does not exist, or you pass no value at the array index (using a variable with void or non numeric value in it). Check the value of the var used.
You're printing out an array using an invalid index value in the for..next iteration. Check to use a valid iterator.
R0106 ERROR R0106: invalid type Array error: one of the index element is missing or is NULL.
Function error: an array was expected but not received (arrays can't be LOCAL)
R0120 ERROR R0120: macro evaluation problem: ERR 6012 : $ Symbol $ (comparison) is not allowed in macro.
If you was trying to pass a macro to a database filter like in  SET FILTER TO &macroeval you need to build a standard condition  not a comparison
3 - Fatal errors
Cod Msg  
F005 FATAL ERROR F005 : Processing Page MAXcp error: string malformed or unterminated. Check the source of the offending page (or frame) for mispelled variables or file names.
F006 FATAL ERROR F006 : Loading CFG File The file is not accessible (blocked by OS)  or already in use by another program (usally same program, when two frames try to access the file at same time). Check you code and be sure you're accessing the file properly (typically this error occurs while reading/writing configuration or .ini files)
F008 FATAL ERROR F008 : [Internal] Unhandled Exception
  1. Table or index damaged or (more often) you are trying to index/reindex using a key on a empty field or the key is longer than 12 characters (that is the max lenght allowed)
  2. Opening a table whose index does not exists (or is still under creation): this happens often if you're using INDEX ON instead of USE..INDEX..KEY..
  3. Call to a page passing parameters resulting in a link that does not exists, is mistyped or with path garbled
  4. Garbage characters (or HEX codes) in the statements: try to check if server-side tags are placed in pairs
  5. Mistyped command (check for parenthesis type, e.g. square brackets or fences in wrong places)
To isolate this problem insert in the source comment(procline()) in different points and when you get the error check the HTML source in browser to see what part of the page was not reached.

Top of page